Need Help With Scoping Potential Arduino Project

I would like to control my attic fans and need help identifying a reasonably priced way to accomplish this. An Arduino may be what I need, I would like to learn from some of the experts to see if they think so.

My problem is the folllowing. I have 2 moderate size ac 120 volt motors, 120 Volt, 8 Amp, approximately 1,000 W each. Startup power requirments are likely to be much higher. (I am assuming these are induction motors). More motor detail can be found here: http://www.amazon.com/Broan-Attic-Ventilator-Motor-97009318/dp/B001IDAA8K/ref=sr_1_fkmr1_1?ie=UTF8&qid=1382113125&sr=8-1-fkmr1&keywords=braun+97009318

I would like to monitor the attic inlet (B) and exhaust temperatures (A). When B is above C (minimum temp threshold temp) and (A - B) > D (max temp difference) I would like to turn my motors on until (A - B) < E (min temp difference). I would like to turn the motors off during certain hours of specific days, this needs to vary depending on the day of the week and the month.

It would be nice to be able to turn the motors on and off with one slightly delayed to minimize the startup current draw.

Where I live attic temps can reach 150 degrees with high humidity for many months which can be tough on electronics located there.

Any advice how to accomplish this at a reasonable cost?

Thanks for sharing your thougts.

A simple and cheap way to control the motors is with relays. You should have no trouble finding ones that will work with your voltage and perhaps 16 amps to give a safety margin and which are switched with a 5v supply like the Arduino uses. You will almost certainly need a small transistor between the Arduino and the relay because the Arduino is unlikely to be able to provide enough current for the relays.

I use a system like this to control a mains (230v) fridge with a temperature sensor in the freezer compartment.

...R

Thanks.

Do you think SSR or conventional relays would be better? Do you know which transistor (company and model) you are using as a switch between the Arduino and the relay before the fridge? Do you have any advice about measuring the temp's and getting this data into the Arduino?

Does the environment seem too harse for the Arduino? Do I need to think about wireless between the Arduino and the relays?

How difficult would it be to program the logic I need into the unit?

Bob1234567890:
Do you think SSR or conventional relays would be better?

Each has advantages and disadvantages. If the motors are induction motors, then they are inductive loads. Switching inductive loads with mechanical relays can be problematic - there are many reports in this forum of the Arduino locking up when the relay is turned on or off. A snubber network should prevent this (and will prolong the life of the relay contacts), however getting the snubber components right can be tricky.

A zero-crossing SSR is not suitable for inductive loads. A random-fire SSR can be used with inductive loads, and can be driven direct from an Arduino pin without needing a transistor. However, random-fire SSRs are harder to find than zero-crossing SSRs, which makes them more expensive. For example, D2425-10 Sensata-Crydom | Relays | DigiKey. The low-cost SSRs you find on eBay are almost always zero-crossing types.

I have no experience of SSRs. As far as I know they are considerably more expensive.

I am probably using a BC337 NPN transistor, but anything similar would do. You would need to ensure it could handle enough current for the coil in your relay. You should have no difficulty finding circuit diagrams for using this sort of thing with an Arduino.

I am using an LM335 temperature sensor. It's very simple to use.

I presume you mean 150F or 66C. The Atmel datasheet for the Atmega 328 says it can operate between -55C and + 125C. The document I have doesn't mention humidity but Google will probably help you. Perhaps the Arduino could be just underneath the attic - close enough to run wires, but not in the extreme conditions.

The programming should be straightforward - measure the voltage produced by the temperature sensor - if the temperature is too high switch on the fans (no problem doing them one at a time) and if it's cold enough, switch off. You would probably include some sort of delay so that they don't go on and off every few minutes.

You can download the Arduino software and experiment with programming without buying any hardware. There are loads of programming examples. It's obviously more fun if you have an Arduino Uno and can see the lights blink.

...R

Thank you.

Robin2 on your fridge application have you experienced any of the lockup issues described by dc42?

Do you have any guess how much relays would cost?

The LM335's seem to be pretty inexpensive. Do you breadboard them up for use? How would that survive in my less than hospitable environment? One temperature measurment needs to be about 35 feet from the unit while the second is about 10 feet away. Would thermistors work better with humdity and heat than a breadboard?

Which Arduino model would work best?

I can't check the price of the relay I used right now - but less than £5, maybe less than £3.

I haven't experimented with lockup problems and haven't had any in the few months my system has been working. Previous to using an Arduino Uno I was controlling the fridge with a "thermostat" made from non-microcontroller electronics, also with a relay. That was working for 2 or 3 years. I changed to the Arduino because it is easier to control and monitor the temperature and I thought there was a problem with the previous electronics - but there wasn't. My fridge runs from an inverter and switching on other devices (such as my PC power supply) can cause the fridge motor to stall and not restart. I thought (incorrectly) that it was interfering with the electronics.

You may get interference on long wires from an LM335 which might be reduced by putting an amplifier near the sensor. But I would try it out first with shielded cable - as used for microphones. You may be able to eliminate the effects of the interference with your program.

I would use an Arduino Uno as it's perfectly adequate and the most standard.

I would use a breadboard for testing but not for operation.

...R

Thanks for sharing your thoughts and experiences.

You mentioned that there should be sources of code available. Where is a good place to look? You also said that it is possible to work on code with no Arduino. How do I do this? When I looked on this site it walked me through getting things up and running on the Arduino. How hard is coding up what I have described?

Do you think that given the harsh environment that wireless would be worth the extra cost and work?

I mean wireless on the temperature sensors and the relays.

I would try the system first without wireless and only consider wireless if it doesn't work. Wireless doesn't really free you from the environment because there will need to be a microprocessor alongside the sensors to make the wireless transmission work.

For the programming side you should download and install the Arduino system on your PC. Then you can examine the example programs (called sketches) and learn how the programs are written. You can also write your own programs, or make modified copies of the examples and "verify" them without needing to have an Arduino board connected to the PC. That should enable you to decide whether you feel competent to develop your own project. You can expect to get lots of help here.

It's important to think of your program as several small pieces rather than a huge complex whole. There will be a liitle bit that checks the temperature, another little bit that switches a relay on and off etc.

...R

How hard is coding up what I have described?

Not very. As ever with such projects, you can subdivide it to make it easier to get something working. A first step would be to just simulate a thermostatic controller for the fans, i.e. just read the temperature in the attic and run the fan when it's too hot.

Then add a temp sensor outside so that you can check whether it's actually worth running the fan. I'm not sure why you would measure the exhaust temp rather than the temp in the shade under the eaves - trying to see whether the fan has done all it can?

Then add a real time clock and add your logic to control your "no fans during this time" logic.

At this point you may well want to know what a good job you're doing, so you may want to put a wireless shield on your arduino and display the data on a service like pachube (or whatever it's called these days) or a local web server.

As well as the switching,
you also mention time, time of day and week / month.

for this you will probably need a real time clock chip. the arduino has no knowledge of time when it starts up,

You might also want to think about monitoring / control .
do you want to go up there to see what the unit is doing, or is a remote monitor the way forward ?

there are answers to this if you want, its complexity compromise.
you could monitor with a long wire, driving LEDs down stairs, or you could use an rs232 link to a down stairs computer, or how about Ethernet or wifi,

Some of the wifi and Ethernet shields also have real time clocks on them, which you could use, else you will have a software timer that needs setting each time the arduino starts, depending how reliable the mains is there.

The attic inlet temperature I referred to is the air entering the attic from the eaves. The exhaust temperature is the air right before the one of the fans exhausts it. This way the fans are only run when they can bring cooler air in than they push out. Right now they run 24 hours a day, 7 days a week when the attic temp is above 75 degrees.

Last night I did see how to download the environment and use it on a PC. I have downloaded it. I do need to identify sources for code that perform portions of the task. These portions are:

Read a temperature sensor.
Control a standard relay.

Do you see any other portions I should be locating to get the minimal functionality up and going?

In the short term, I can go to the unit in the attic if it makes things simpler to get up and running. In the medium/long term, it would be nice to minimize the amount of trips there. Is it possible to make either the relays or the sensors remote without having a processor in the attic? If the unit is in the attic, how much complexity and cost does it add to be able to access it remotely (wirelessly) from a PC. It would be nice to be able to monitor it (see when it has issues) and maybe make changes to the program remotely.

wifi shield

can give you access to the arduino
but you cant reprogram remotely,

there are others.

I'd suggest the arduino up by the 'relays' and what ever you control
I;d also strongly suggest the rugged arduino

http://ruggedcircuits.com/html/ruggeduino.html

USD 10 more, but much more rugged than the original, especially in the power in / out portion.

,

Thanks. I'll take a look at them.

I have the ability, with my fridge controller to plug my PC into it to read data (or to change the program). It is right behind me as I type, so access is simple. The reality is that I don't bother. It works. I do other stuff.

Adding WiFi would be possible but you also need to write software on your PC, or webserver code on the Arduino. If you are a novice that is likely to be much harder than writing simple sensor/relay code.

I would start by seeing if you could get your system to work with long wires from the sensors and relays so that the Arduino could be in a room below the attic. Long wires from the sensors may cause problems but it seems to me it would be well worth trying for the simplicity.

If the long wires won't work or are just not suitable I would consider using two Arduino Unos - one in the attic and one in a room below. They could communicate by wireless and it would be much simpler to program than a WiFi solution. You could then plug your PC into the accessible Uno. Even though simpler than WiFi there will be considerably more programming if you have 2 Unos so even if I was planning to go that route I would start with a wired solution. It would make no sense to start with wireless if the basic system can't work.

Indeed I should amend my 3rd para to say that you should start with short wires to get a system that works on the kitchen table.

I have a feeling you are close to the point where you need to get some practical experience rather than continue with a "classroom" discussion.

...R

Thanks for everyone's help.

I have ordered an Uno, relays and temperature sensors.

I have started modifying some code to read the sensors. Once it is in better shape I will post it and get some feedback to see if it will work.

The "tougher" Ardinuo looks like a good idea. I had ordered a regular one before I saw it.