Chick Incubator

Hello, I'm thinking on building a chicken incubator. I need some advise on the microcontroller.

To heat I'll use a ceramic heat lamp (220 V AC). To control heat I want to use AC dimming (I've done this before with Triac, MOC3011 and optocouplers). To regulate temp I'd like to use PID library. And for display a common LC 16x2. Sensing temperature can be done by a lm35.

So the main tasks are Ac dimming and PID rutine (besides temp reading and LCD displaying). I'd like to know if Arduino UNO (Atmega328p) is capable of managing this boths task. I've never used PID library. I don't know much about microcontroller resources and operating besides flash memory :relaxed:, so I don't know if it will get stuck of much computing or something like that (I know it is not a laptop).

Thanks for any advice.

I made an AC dimmer using an Arduino Pro Micro, which is the same clock rate as the atmega328 , but it has an extra hardware timer which helped control the dimmer.

The dimmer was controlled via wireless using the RCSwitch library. And it all worked fine.

So I think that operating a dimmer and sensor and pic should be ok, assuming the LCD doesn't need constant updates

Ps. I programmed the dimmer to totally work on interrups, and the RCSwitch ran in the main loop

Look at the PID_library example : https://github.com/br3ttb/Arduino-PID-Library/blob/master/PID_v1/Examples/PID_Basic/PID_Basic.ino . This is exactly what you are looking for . Just add other stuf, change bits and pieces and tune the parameters . You can use SSR ( Solid State Relay ) to controll the heater by PWM from arduino.

It’d be a lot simpler to skip the phase angle switching and just go with a SSR to switch the lamp on/off. Your eggs aren’t going to notice the unevenness of heat if you’re switching at a base rate of 60 times/second; they certainly don’t notice the fact that most incubators switch their elements at a rate of once every few minutes. I’d suggest you put the effort into humidity control instead.

DS18B20 sensors offer a better accuracy/precision vs. price (~$3) for temperature sensing. Much better than LM35s.

Hi, I agree with Chargin. You don’t need to control the temperature with that much precision. Get that working well enough and then focus on humidity control, which is also important for hatching healthy chicks. Most humidity sensors measure temperature as well. An audible alarm to prompt you to manually top up a water reservoir when needed rather than any complex mechanical means to dispense water (maybe later). Humidity needs to follow an ideal pattern throughout the 21-day hatching process, the Arduino could have that programmed in to control the alarm.

Paul

DHT11 or DHT22 for temperature and humidity

Note the latter library is not updated recently.

When you say pwm you mean time proportion control right? The slow version of pwm. Seems enough and easier this way, I didnt know there exists solid state relays lol. In fact I didnt want to use relay because they do a noise when closed I guess ssr dont do noise (maybe they are a triac). I'll add humidity sensors and manually increase it. Thanks for the responses

mart256: I didnt want to use relay because they do a noise

Our incubator has a fan to circulate the air and keep the eggs evenly warm. I'm pretty sure this must also be important. That will make more noise than a relay.

SSR = Solid State Relay. Basically your triac, optocoupler, etc. in a tidy package. No noise / no moving parts.

PaulRB:

mart256: I didnt want to use relay because they do a noise

Our incubator has a fan to circulate the air and keep the eggs evenly warm. I'm pretty sure this must also be important. That will make more noise than a relay.

I will use forced air with fan too. I dont care if it is a noisy fan, it's jus the "click" of the mechanic relays that bothers me :P

Add an alarm to your design.

Have you considered using a conventional programmable domestic central heating controller? They’re pretty simple to wire up, have the capability to switch mains voltages directly, and it’s common these days to have ‘time proportional’ control which means they apply the appropriate heating duty cycle for you to maintain the target temperature with minimal temperature fluctuations. They also give you a working reliable solution off the shelf, with a nice simple UI.

PeterH: Have you considered using a conventional programmable domestic central heating controller?

They run off 24VAC power and that's what they're designed to switch as well. Or at least that's how they work in the US. Not a complete show stopper but getting things to work with one properly ... I dunno.

In my country those controllers are more expensive than a microcontroller, and i cannot check humidity with them nor use alarms. And there would be no fun not programming and soldering too :slight_smile:

If its still relevant you can check my incubator Homemade digital incubator самодельный инкубатор - YouTube

Works perfectly.

Zen-: If its still relevant you can check my incubator https://www.youtube.com/watch?v=7Pu5BrQU5ds

Works perfectly.

Nice incubator, very sturdy. But, why is the box so high? Is it a design feature or could it be shorter in height? Have you hatched some chicks yet?

mart256:

Zen-: If its still relevant you can check my incubator https://www.youtube.com/watch?v=7Pu5BrQU5ds

Works perfectly.

Nice incubator, very sturdy. But, why is the box so high? Is it a design feature or could it be shorter in height? Have you hatched some chicks yet?

It can be shorter of course, the inner height is 35cm.

I'm currently incubating 10 quail eggs for experiment, the temperature is very very steady. I'm using PID library for the temperature and it's doing the job more than i expected.

Share photos or video when eggs are hatched please :)

mart256: Share photos or video when eggs are hatched please :)

No problem.

mart256: Share photos or video when eggs are hatched please :)

As i promised here some photos.

5 of 5 eggs at the left side and 3 of 6 eggs at the right side. I don't know if the 3 in the right side will hatch, i will check it if the eggs were fertile or they were empty from the beginning. Even though 8 from 11 is 73%. The plastic bag is just for keeping the incubator floor clean.

http://i.imgur.com/pqTQSLO.jpg http://i.imgur.com/9ecL1aX.jpg http://i.imgur.com/Md8mGMm.jpg http://i.imgur.com/s8yFNec.jpg