Skip to content

Liquid Filling Machine – Liquid Filler Part 1

Liquid Filler at 20Kg

Liquid filler will be our first complete project here at hw2sw! 😎
We have made a series of articles that we will use in order to reach our goal.
Liquid filler is exactly as its name says, an really cheap but accurate liquid  filling machine.
We need to auto-fill bottles with a certain capacity (50 up to 8500gr).
This arduino based project will permit to fill all containers with a certain, user defined, weight limit.
So the machine works on weight base and not on volume, flow or pressure base like other fillers.
Other than the  machine you see in the photo, you need a weighting board that the bottle will sit on and a gravity feed valve that is piloted by liquid filler.
The present solution will weight containers up to 8,5 Kg.

Liquid filler design
Oil Container

As we can see from the picture liquid filler measures the weight of the bottle and when the weight limit , given by the user before, is reached then closes the valve.
Notice that we are talking about a gravity feed valve since we do not use any pump but only the gravity force to fill the bottles.
The user has the possibility to store a weight limit measured in grams.
So keep in mind that the weight sensor should have a gram resolution.
The containers can be non transparent like the photo beside.

The first aim of this project is to be user friendly. So we added a LCD with a circular menu.

From the article Connecting a LCD to an Arduino we already know how to connect a LCD 16x2  into our liquid filler project.
So we need to buid this partial circuit :

Liquid filler, the LCD schematic

Notice that we are using two resistors (1K,10K) and not a potentiometer in order to keep the project cheap. By doing this we fix the contrast at a certain value.

 

 

A LCD ,as is, does not help us a lot. The user needs to interact with the machine pretty easily.
This can be obtained with the use of a circular menu. The circular menus are discussed in their dedicated page.
In order to keep the project as simple as we could, we did not made a multilevel menu and for that we didn't use the CircularMenuAdvanced example but only the simpler example discussed in the 2nd page of that article.
So class and object oriented knowledge is not required.

The last consideration at this point is the possibility that has the user to store a selected weight limit.
At the article Arduino and memory how to we have seen that we need to use the EEPROM library in order to store variables.
Remember that the stored weight value should be in grams.
EEPROM library stores at max one byte at a time.
From the Binary Decimal and Hexadecimal numeral systems we know that a byte can hold 256 possible values.
The problem here is that the user need to store values up to 8500 in grams.
In order to solve this problem you must go deeper and see the "EEPROM and Arduino. A deeper view" article.
With the help of the bitwise operators  you can overcome this problem.

In the next page we will see the first part of the code and the partial realization of liquid filler into a breadboard.