IOT Flower Pot Weighing Scale

by litchiate in Circuits > Arduino

2184 Views, 6 Favorites, 0 Comments

IOT Flower Pot Weighing Scale

miyan.jpg
P1080337.jpg
P1080361.jpg
P1080362.jpg

I want to introduce my IOT Flower Pot Weighing Scale, it can get and log the weight of a flower pot continuously. So the soil moisture can be get directly. And when the plant need water can be known.

Why using weighing method not measuring capacitance or resistance?

1. a probe needed to be inserted in the pot, it may hurt plant root.

2. measuring capacitance or resistance can't get direct soil moisture value.

For example, my Sinn. 'Stone's Georgia' is 287g when the soil a little dry.

After watering , it became 460g, the 173g is water.

First picture is my Sinn. 'Stone's Georgia' ,taken last year.

How It Works

P1080339.jpg
P1080342.jpg

Before weighing,a clear operation is needed to prevent zero drift or temperatue drift or something like that.

The load cell is mounted between the baseboard and fixed plate. One end of the movable plate is connected with a hinge and the other end is placed above aeccentric wheel.

The aeccentric wheel is driven by a MG995 Servo. In top position, the Flower Pot will stand upon the movable plate. Clear operation can be done. In bottom position, the Flower Pot will stand upon the fixed plate. Weighing operation can be done. To prevent damage load cell, at most time the Flower Pot will stand upon the moveable plate. Nodemcu is used to read load cell ,control server and send data to IOT server via WIFI using MQTT protocol.

Collect What You Need

P1080356.jpg
P1080360.jpg
nodemcu.jpg
hx711.jpg
mg995.jpg

Here is a list of everything that is needed for this project:

1. weighing scale ( using its Load Cell )

2. HX711 module

3. NodeMCU with ESP-12E

4. MG995 Servo

5. 5mm thickness ABS Board

6. some 3D printed parts

7. some cable

8. M3 and M4 screws and nuts

Make the Weighing Scale

2.png
P1080347.jpg
P1080353.jpg
P1080348.jpg
P1080351.jpg
P1080352.jpg

200*250*5 mm ABS board is used as the base of the Weighing Scale.

Load cell is mounted on the board.

Fix plate is composed with the original plate and a 3d printed part.

Movable plate is a 180*190*5mm ABS board with another 5mm ABS reinforcing rib.

The hinge, servo holder , aeccentric wheel is 3d print part.

Glue or screw them.

A sketchup file can tell you where to put parts.

Wiring

P1080337.jpg
Schematic_IOT-Pot-Weigh_Sheet-1_20190526154450.png

Wire them up.

If ESP8266 deep sleep is used ,GPIO16 and RST pin should be connected, no use in this application.

Coding

Arduino is used, and HX711 library is used, here the link

https://github.com/bogde/HX711

Nodemcu sends MQTT message to a domoticz server in my NAS. So MQTT client library needed.

https://github.com/knolleary/pubsubclient

A bug with HX711 library, that is a software reset will occur when connecting MQTT server after including HX711 library. Comment "void yield(void) {};" in HX711.CPP can solve the problem.

Your SSID , Password, MQTT setting should be modified before using.

const char* ssid = "YOUR SSID";

const char* password = "YOUR PASSWORD";

const char* mqtt_domoticz = "YOUR SERVER";

Downloads

Calibration

weight.png
P1080362.jpg

Refer instruction in HX711 library.

1. Call set_scale() with no parameter.

2. Call tare() with no parameter.

3. Place a known weight on the scale and call get_units(10).

4. Divide the result in step 3 to your known weight. You should get about the parameter you need to pass to set_scale().

5. Adjust the parameter in step 4 until you get an accurate reading.

Summarize

It is my first article in English, some mistakes, maybe.

Some other function may be added, such as weight display, watering.