include LCD library
include HX711 library
include WiFi library
include Blynk library
define constant & variables
[fluid types, flow rate, currentWeight, weight threshold]
define pins & buttons
void setup() {
Start Blynk and WiFi connection;
Initialize pins and buttons;
Initialize LCD display with a welcome message;
Initialize HX711 and tare the scale;
Display currentWeight on LCD;
while (ENT !pressed){
Display fluid type options on LCD
Cycle through options using SEL button
Confirm selection using ENTER button
}
while (ENT !pressed){
Display flow rate options on LCD
Cycle through options using SEL button
Confirm selection using ENTER button
}
Display final settings on LCD
Wait for user confirmation with ENTER button
}
void loop() {
Connect to Blynk;
Define Callibration factor;
Define suppoedWeight equation;
Read current weight from scale
Display currentWeight and connection status on LCD
Send weight, fluid type, and flow rate data to Blynk
if (weight is < threshold){
activate buzzer alarm;
send notification to Blynk;
}
if (currentWeight is > supposedWeight){
send notification to Blynk;
}
}