Automated Chicken Feeder System Using Arduino
Automated Chicken Feeder System Using Arduino
This design mimics a simple PLC-based automated chicken feeder system. The main
components include sensors and actuators, controlled by an Arduino board to automate the
process of feeding chickens. We will use sensors like a weight sensor to detect if the food is low
and a motor to dispense the food. Additionally, we will use limit switches or photo sensors to
detect when the chickens are close to the feeder.
Components Needed:
Basic Concept:
The load cell will measure the weight of the food in the container.
When the food level is low, the Arduino will trigger the DC motor to dispense food.
Limit switches will detect when the chickens are near the feeder and stop the feeding
process.
System Diagram:
+-----------------------------------+
| |
| Automated Chicken |
| Feeder System |
| |
+-----------------------------------+
| |
| |
+-------+---+--------+
| Load Cell (HX711) |
| (Food Weight Sensor) |
+---------------------+
|
| (Arduino Reads Data)
|
+------+------+
| Arduino |
| (UNO) |
+------+------+
|
+-------+-------+
| DC Motor |
| (Motor Driver)|
+---------------+
|
+-------+-------+
| Power Supply |
| (5V and 12V) |
+---------------+
// Pin definitions
#define DOUT 3 // Data pin of HX711
#define CLK 2 // Clock pin of HX711
#define motorPin 9 // Pin for motor control
#define limitSwitch 7 // Pin for limit switch (detect if chicken is near)
void setup() {
Serial.begin(9600);
scale.begin(DOUT, CLK); // Initialize the load cell
feederMotor.attach(motorPin); // Attach the servo motor to the pin
pinMode(limitSwitch, INPUT_PULLUP); // Initialize limit switch pin
}
void loop() {
currentWeight = scale.get_units(10); // Get average weight from load cell
// Check if the food weight is less than the threshold and chicken is near
if (currentWeight < weightThreshold && digitalRead(limitSwitch) == LOW) {
Serial.println("Feeding chickens...");
feedChickens();
}
void feedChickens() {
// Rotate the motor to dispense food
feederMotor.write(90); // Dispense food (servo turns to 90 degrees)
delay(2000); // Dispense for 2 seconds
feederMotor.write(0); // Stop dispensing food (servo returns to 0 degrees)
delay(1000); // Wait for 1 second before next action
}
HX711 Library: Used for interfacing the load cell to measure the food weight.
Servo Library: Controls the DC motor (if using a servo for dispensing food).
The program continuously checks the food weight. If it falls below a threshold, it
activates the motor to dispense food.
A limit switch is used to detect if chickens are close. The feeding happens only when this
switch is triggered (indicating chickens are near).
The weight threshold is set to 500 grams, and the motor dispenses food for 2 seconds.
How it Works:
1. The load cell detects the weight of the food in the feeder container.
2. If the food weight is lower than the threshold, the system checks the limit switch to see if
chickens are nearby.
3. If the switch is activated (i.e., chickens are near), the motor is turned on to dispense the
food for a fixed period.
4. After the motor runs, the system waits for the next check.
This simple automation system provides a way to automate feeding, ensuring that chickens are
fed when necessary without requiring constant manual intervention.
Visualization: