Boaz Lawnce
Published © GPL3+

Electronic Weighing Machine

Arduino Uno-based electronic weighing machine by 5-wire 3 kg load cell.

AdvancedFull instructions provided17,983
Electronic Weighing Machine

Things used in this project

Story

Read more

Schematics

Circuit

Code

Code

C/C++
/*
 * https://facebook/nissiembeddedlab
 * 2018 September 4
 * 3 Kg Load Cell HX711 Module Interface with Arduino to measure weight in Kgs
 Arduino  pin  2 -> HX711 CLK 3 -> DOUT 5V -> VCC GND -> GND
*/

#include "HX711.h"  
#define DOUT  3
#define CLK  2

HX711 scale(DOUT, CLK);
#include <Wire.h>
#include <LiquidCrystal_PCF8574.h>

LiquidCrystal_PCF8574 lcd(0x3F);
float calibration_factor = -96650;
const int SW = 7;
void setup() 
{
  Wire.begin();
  Wire.beginTransmission(0x3F);
  pinMode(SW, INPUT_PULLUP);
  lcd.setBacklight(255);
  lcd.begin(16, 2);
  lcd.setCursor(0,0);
  lcd.print("Nissi 3kgLoadCell");
  lcd.setCursor(0,1);
  lcd.print("Press Sw to tare");
  scale.set_scale(-849650); 
  scale.tare();           
}
void loop() 
{
  lcd.setCursor(0,1);
  lcd.print("W =  ");
  lcd.setCursor(6,1);
  lcd.print(scale.get_units(),3); 
  lcd.println(" kg   ");
  int x = digitalRead(SW);
  if(x == LOW)
  {
      scale.tare();  
  }
}

Credits

Boaz Lawnce

Boaz Lawnce

11 projects • 30 followers
Electronics Engineer, Founder, Hobbyist....

Comments