Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use hx711: Examples, Pinouts, and Specs

Image of hx711
Cirkit Designer LogoDesign with hx711 in Cirkit Designer

Introduction

The HX711 is a precision 24-bit analog-to-digital converter (ADC) designed for applications requiring high accuracy and stability. It is widely used in weigh scales and industrial control systems due to its ability to interface directly with load cells. The HX711 features a built-in low-noise programmable gain amplifier (PGA), making it ideal for amplifying small signals from load cells and other sensors.

Explore Projects Built with hx711

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Arduino Mega 2560-Based Smart Weighing System with Bluetooth Connectivity
Image of SMART BRIDGE CIRCUIT DIAGRAM: A project utilizing hx711 in a practical application
This circuit is a weighing system that uses two load cells connected to HX711 modules for weight measurement, interfaced with an Arduino Mega 2560. The system includes an LCD for displaying weight, a Bluetooth module for wireless communication, and LEDs for status indication, with a micro servo for additional mechanical control.
Cirkit Designer LogoOpen Project in Cirkit Designer
Raspberry Pi and ESP8266-Based Smart Weighing System with Camera Integration
Image of CAPSTONE HARDWARE: A project utilizing hx711 in a practical application
This circuit integrates multiple HX711 weighing sensor modules connected to load cells for weight measurement, an OV7725 camera module interfaced with a Raspberry Pi 4B for image capture, and a WeMOS ESP8266 for wireless communication. Additionally, it includes an Adafruit 24-Channel PWM LED driver for controlling LEDs and a buzzer module for audio alerts.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino Mega ADK and HX711 Weighing Sensor Rain Detection System with LED Indicator
Image of raindrop: A project utilizing hx711 in a practical application
This circuit uses an Arduino Mega ADK to interface with an HX711 weighing sensor module to measure weight. When the weight exceeds a predefined threshold, the Arduino lights up a red LED for 60 seconds. The system is designed to detect and indicate the presence of a raindrop or similar event.
Cirkit Designer LogoOpen Project in Cirkit Designer
Smart Weighing System with ESP8266 and HX711 - Battery Powered and Wi-Fi Enabled
Image of gggg: A project utilizing hx711 in a practical application
This circuit is a multi-sensor data acquisition system powered by a 18650 battery and managed by an ESP8266 microcontroller. It includes a load sensor interfaced with an HX711 module for weight measurement, an IR sensor, an ADXL345 accelerometer, a VL53L0X distance sensor, and a Neo 6M GPS module for location tracking. The system is designed for wireless data transmission and is supported by a TP4056 module for battery charging.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with hx711

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of SMART BRIDGE CIRCUIT DIAGRAM: A project utilizing hx711 in a practical application
Arduino Mega 2560-Based Smart Weighing System with Bluetooth Connectivity
This circuit is a weighing system that uses two load cells connected to HX711 modules for weight measurement, interfaced with an Arduino Mega 2560. The system includes an LCD for displaying weight, a Bluetooth module for wireless communication, and LEDs for status indication, with a micro servo for additional mechanical control.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of CAPSTONE HARDWARE: A project utilizing hx711 in a practical application
Raspberry Pi and ESP8266-Based Smart Weighing System with Camera Integration
This circuit integrates multiple HX711 weighing sensor modules connected to load cells for weight measurement, an OV7725 camera module interfaced with a Raspberry Pi 4B for image capture, and a WeMOS ESP8266 for wireless communication. Additionally, it includes an Adafruit 24-Channel PWM LED driver for controlling LEDs and a buzzer module for audio alerts.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of raindrop: A project utilizing hx711 in a practical application
Arduino Mega ADK and HX711 Weighing Sensor Rain Detection System with LED Indicator
This circuit uses an Arduino Mega ADK to interface with an HX711 weighing sensor module to measure weight. When the weight exceeds a predefined threshold, the Arduino lights up a red LED for 60 seconds. The system is designed to detect and indicate the presence of a raindrop or similar event.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of gggg: A project utilizing hx711 in a practical application
Smart Weighing System with ESP8266 and HX711 - Battery Powered and Wi-Fi Enabled
This circuit is a multi-sensor data acquisition system powered by a 18650 battery and managed by an ESP8266 microcontroller. It includes a load sensor interfaced with an HX711 module for weight measurement, an IR sensor, an ADXL345 accelerometer, a VL53L0X distance sensor, and a Neo 6M GPS module for location tracking. The system is designed for wireless data transmission and is supported by a TP4056 module for battery charging.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications

  • Digital weigh scales
  • Industrial process control
  • Force measurement systems
  • IoT-based weight monitoring
  • Laboratory equipment

Technical Specifications

The HX711 is designed to provide high-resolution measurements with minimal external components. Below are its key technical details:

Key Features

  • Resolution: 24-bit ADC
  • Input Channels: 2 differential input channels (Channel A and Channel B)
  • Programmable Gain: 128 or 64 for Channel A, fixed gain of 32 for Channel B
  • Operating Voltage: 2.6V to 5.5V
  • Current Consumption: ~1.5mA (normal mode), <1µA (power-down mode)
  • Data Rate: 10Hz or 80Hz
  • Interface: Serial (2-wire interface: Data and Clock)
  • Temperature Range: -40°C to +85°C

Pin Configuration

The HX711 has 16 pins, but in most applications, only 10 pins are used. Below is the pin configuration:

Pin Name Description
1 VCC Power supply (2.6V to 5.5V).
2 AVDD Analog power supply (connect to VCC).
3 VFB Feedback voltage for internal regulator (connect to ground via a capacitor).
4 AGND Analog ground.
5 BGND Bridge ground (connect to load cell ground).
6 B- Negative input for load cell.
7 B+ Positive input for load cell.
8 A- Negative input for load cell (Channel A).
9 A+ Positive input for load cell (Channel A).
10 DGND Digital ground.
11 PD_SCK Power-down and serial clock input.
12 DOUT Serial data output.
13-16 NC Not connected (leave unconnected).

Usage Instructions

Connecting the HX711 to a Load Cell

  1. Power Supply: Connect the VCC pin to a 3.3V or 5V power source and the GND pin to ground.
  2. Load Cell Connections:
    • Connect the load cell's positive excitation wire to the B+ pin.
    • Connect the load cell's negative excitation wire to the B- pin.
    • Connect the load cell's positive signal wire to the A+ pin.
    • Connect the load cell's negative signal wire to the A- pin.
  3. Microcontroller Interface:
    • Connect the PD_SCK pin to a digital output pin on the microcontroller.
    • Connect the DOUT pin to a digital input pin on the microcontroller.

Example Arduino UNO Code

Below is an example of how to use the HX711 with an Arduino UNO to read weight data from a load cell. This code uses the popular HX711 library.

#include "HX711.h" // Include the HX711 library

// Define the pins connected to the HX711
#define DOUT  3  // Data output pin
#define CLK   2  // Clock pin

HX711 scale; // Create an instance of the HX711 class

void setup() {
  Serial.begin(9600); // Initialize serial communication
  scale.begin(DOUT, CLK); // Initialize the HX711 with the defined pins

  // Set the scale to zero (tare)
  Serial.println("Taring the scale...");
  scale.set_scale(); // Set the scale factor to default
  scale.tare();      // Reset the scale to zero
  Serial.println("Scale tared.");
}

void loop() {
  // Read the weight from the load cell
  if (scale.is_ready()) { // Check if the HX711 is ready
    long weight = scale.get_units(); // Get the weight in units
    Serial.print("Weight: ");
    Serial.print(weight);
    Serial.println(" units");
  } else {
    Serial.println("HX711 not ready. Check connections.");
  }

  delay(500); // Wait for 500ms before the next reading
}

Important Considerations

  • Power Supply: Ensure a stable power supply to avoid noise in the readings.
  • Taring: Always tare the scale before taking measurements to ensure accuracy.
  • Shielding: Use shielded cables for the load cell to minimize interference.
  • Data Rate: Use the appropriate data rate (10Hz or 80Hz) based on your application's requirements.

Troubleshooting and FAQs

Common Issues

  1. No Data Output:

    • Cause: Incorrect wiring or loose connections.
    • Solution: Double-check all connections, especially the DOUT and PD_SCK pins.
  2. Unstable Readings:

    • Cause: Electrical noise or unstable power supply.
    • Solution: Use a decoupling capacitor (e.g., 0.1µF) between VCC and GND. Ensure proper grounding.
  3. Incorrect Weight Measurements:

    • Cause: Improper calibration or load cell issues.
    • Solution: Calibrate the scale using a known weight. Verify the load cell's wiring.
  4. HX711 Not Ready:

    • Cause: Faulty HX711 module or incorrect clock signal.
    • Solution: Replace the HX711 module. Verify the clock signal from the microcontroller.

FAQs

Q1: Can the HX711 work with a 3.3V microcontroller?
Yes, the HX711 operates with a supply voltage as low as 2.6V, making it compatible with 3.3V systems.

Q2: How do I calibrate the HX711?
Use a known weight to determine the scale factor. Adjust the scale factor in your code using the set_scale() function.

Q3: Can I use both channels (A and B) simultaneously?
Yes, but note that Channel A has a programmable gain (128 or 64), while Channel B has a fixed gain of 32. Channel A is typically used for higher precision measurements.

Q4: What is the maximum weight the HX711 can measure?
The maximum weight depends on the load cell's capacity. The HX711 itself does not impose a weight limit but converts the load cell's output signal.

Q5: How do I reduce noise in the readings?
Use a stable power supply, shielded cables, and proper grounding. Additionally, average multiple readings in your code to filter out noise.