Mostly PLCs are used for Automatic bottle filling machines, but you can make a very basic and versatile bottle filler using an Arduino. You can program the Arduino to automatically detect the bottle using IR or ultrasonic sensor and allow the bottler to fill by stopping the conveyer belt for some time. Then again move the belt and stop when the next bottle is detected.

In this Arduino project we design a prototype for Automatic Bottle Filling Machine using Arduino Uno, conveyor belt, solenoid valve, IR sensor, and Stepper motor. Belt conveyor is driven by a stepper motor at a constant preset speed. The stepper motor will keep driving the belt until an IR sensor detects the presence of a bottle on the belt. We used the IR sensor as an external trigger. So whenever the IR sensor goes high it sends a trigger to Arduino to stop the motor and turn on the solenoid valve. A preset required delay is already entered in the code for bottle filling. The Arduino will keep the solenoid valve on and stepper motor off until that specified time. After that time, the solenoid valve turns off the filling, and the conveyor starts moving so that the next bottle can be filled.

 

Below are the components required for this project:

You can read more details of the project and download the circuit diagram and source code from here: