Smart Cumulative Weighing Scale HX711 Using Visuino

by RonFrtek in Circuits > Arduino

114 Views, 3 Favorites, 0 Comments

Smart Cumulative Weighing Scale HX711 Using Visuino

Smart Cumulative Weighing Scale HX711 using Visuino

This innovative weighing scale, built with Visuino, lets you track the combined weight of multiple items in real time. Simply place an item on the scale, register its weight, add another, and watch the total update automatically! This project builds on the foundational design from this Arduino scale tutorial on Instructables, utilizing an HX711 load cell and the intuitive Visuino platform for seamless setup and operation.

Watch the video!

What You Will Need

Scale With HX711.png
FZEK4WBK3XGYAP0.LARGE.jpg
djownload.jpg
breadboard.png
button.png
F5OFEUQJJ4ZYFKY.LARGE.jpg
F7WXB0JJJ4ZYGGX.LARGE.jpg
VisuinoAdvrtisemenPortentaC33-small.png
  1. Arduino board (or any other board)
  2. Breadboard
  3. One Weight Load Cell
  4. One HX711 ADC Sensor Module for Load Cells
  5. OLED Display
  6. Breadboard
  7. Button
  8. 1K ohm resistor
  9. Jumper wires
  10. Visuino program: Download Visuino


Note: You can purchase online Weight Load Cell and HX711 ADC Sensor Module together already as a kit.

The Circuit

2024-11-14_19-52-34.jpg
  1. Connect the Red wire from the Load Cell (Picture 1) to the E+ pin of the HX711 module
  2. Connect the Black wire from the Load Cell (Picture 1) to the E- pin of the HX711 module
  3. Connect the White wire from the Load Cell (Picture 1) to the A- pin of the HX711 module
  4. Connect the Green wire from the Load Cell (Picture 1) to the A+ pin of the HX711 module


  1. Connect HX711 ADC Sensor Module Ground wire(Black wire) to Ground pin of the Arduino board
  2. Connect HX711 ADC Sensor Module Power wire(Red wire) to 5V pin of the Arduino board
  3. Connect HX711 ADC Sensor Module  DT wire(Green wire) to Digital pin 3 of the Arduino Nano board
  4. Connect HX711 ADC Sensor Module  SCK wire(Yellow wire) to Digital pin 2 of the Arduino Nano board


  1. Connect OLED Display pin [SCL] to Arduino pin [SCL]
  2. Connect OLED Display pin [SDA] to Arduino pin [SDA]
  3. Connect OLED Display pin [VCC] to Arduino pin [5v]
  4. Connect OLED Display pin [GND] to Arduino pin [GND]


  1. Connect Arduino Digital pin [4] to button on the breadboard and to the Resistor
  2. Connect other side of the resistor to the breadboard pin [GND]
  3. Connect Other pin of the button to the breadboard positive pin [5V]
  4. Connect Arduino pin [5V] to breadboard positive pin [Red line]
  5. Connect Arduino pin [GND] to breadboard negative pin [Black line]


Calibrating the Scale

Please check this tutorial on how to calibrate the scale, especially Part 8: Set the Weight Zero Offset for the HX711 Component



Start Visuino, and Select the Arduino Board Type

select-board-uno.jpg
Visuino-Select-Board-UNO.jpg

Start Visuino as shown in the first picture Click on the "Tools" button on the Arduino component (Picture 1) in Visuino When the dialog appears, select "Arduino UNO" as shown on Picture 2

In Visuino Add & Set Components

2024-11-14_19-58-09.jpg
2024-11-14_19-57-50.jpg
2024-11-14_20-50-22.jpg
2024-11-14_20-51-22.jpg
2024-11-14_20-52-21.jpg
2024-11-14_20-53-08.jpg
2024-11-14_20-53-55.jpg
2024-11-14_20-55-11.jpg
2024-11-14_20-55-50.jpg
2024-11-14_20-56-38.jpg
2024-11-14_20-57-23.jpg
2024-11-14_20-58-08.jpg
2024-11-14_20-59-26.jpg
2024-11-14_21-01-34.jpg
2024-11-14_21-03-56.jpg
2024-11-14_21-04-22.jpg
2024-11-14_21-04-39.jpg
2024-11-14_21-05-04.jpg
2024-11-14_21-05-23.jpg
  1. Add "Weight Scale HX711" component and do the calibration like in this tutorial
  2. Add "Detect Edge" component
  3. Add 2X "Analog Multi Source" component
  4. Add "Compare Analog Value" component
  5. Add "Digital Multi Source" component
  6. Add "Analog On/Off Switch" component
  7. Add "Debounce Button" component
  8. Add "Clock Multi Source" component
  9. Add "Add Analog" component
  10. Add "Remember Analog Value" component
  11. Add "OLED I2C" component


  1. Select "Compare1" component and in the properties window set "Compare Type" to ctBiggerOrEqual
  2. Select "DetectEdge1" and in the properties window set "On Rising/True" to False
  3. Double click on the "DisplayOLED1" and in the "Elements" window drag "Draw Text" to the left side and in the "Properties" window set "Size" to 1 and "Text" to "Weight (g)"
  4. In the "Elements" window drag "Text Field" to the lefty side and in the "Properties" window set "Size" to 3 and "Y" to 15
  5. in the "Elements" window drag "Draw Text" to the left side and in the "Properties" window set "Size" to 1 and "Text" to "Total:" and "Y" to 48
  6. In the "Elements" window drag "Text Field" to the lefty side and in the "Properties" window set "Size" to 2 and "Y" to 48 and "X" to 40
  7. Close the "Elements" window


In Visuino Connect Components

2024-11-14_21-06-11.jpg
2024-11-14_21-06-44.jpg
SmartScale.png
  1. Connect Arduino Digital pin [3] to "WeightScale1" pin [Sensor Data]
  2. Connect "WeightScale1" pin [Sensor Clock] to Arduino Digital pin [2]
  3. Connect "DetectEdge1" pin [Out] to "WeightScale1" Pin [Zero]
  4. Connect "WeightScale1" pin [Out] to "MultiSource4" Pin [In]
  5. Connect "MultiSource4" pin [0] to "Compare1" pin [In]
  6. Connect "MultiSource4" pin [1] to "Switch1" pin [In]
  7. Connect "Compare1" pin [Out] to "MultiSource5" pin [In]
  8. Connect "MultiSource5" pin [0] to "Switch1" pin [Enable]
  9. Connect "MultiSource5" pin [1] to "DetectEdge1" pin [In]
  10. Connect "Switch1" pin [Out] to "MultiSource3" pin [In]
  11. Connect "MultiSource3" pin [0] to "Add1" pin [0]
  12. Connect "MultiSource3" pin [1] to "DisplayOLED1" > "Text Field1" pin [In]
  13. Connect Arduino digital pin [4] to "Button1" pin [In]
  14. Connect "Button1" pin [Out] to "MultiSource1" pin [In]
  15. Connect "MultiSource1" pin [0] to "Add1" pin [Clock]
  16. Connect "MultiSource1" pin [1] to "Remember1" Pin [Remember]
  17. Connect "MultiSource2" pin [0] to "DisplayOLED1" > "Text Field2" pin [In]
  18. Connect "Remember1" pin [Out] to "Add1" pin [1]
  19. Connect "DisplayOLED1" pin I2C [Out] to Arduino pin I2C [In]


Generate, Compile, and Upload the Arduino Code

Visuino-Compile-UNO.jpg

In Visuino, at the bottom click on the "Build" Tab, make sure the correct port is selected, then click on the "Compile/Build and Upload" button.

Play

Congratulations! You have completed your project with Visuino. Also attached is the Visuino project, that I created for this tutorial, you can download it and open it in Visuino: https://www.visuino.eu