Table of Contents

LamaPLC: HX711 24-bit analog-to-digital converter (ADC)

HX711 24-bit analog-to-digital converter (ADC) The HX711 is a widely used, low-cost 24-bit analogue-to-digital converter (ADC) integrated circuit with an internal amplifier, specifically designed to interface directly with bridge sensors such as load cells and strain gauges.

It is a popular component for DIY and commercial weighing-scale projects using microcontrollers such as Arduino and Raspberry Pi.

Key Features

Applications

The primary application of the HX711 is to build precise weight and force measurement systems.

HX711 with a load cell

HX711 with a load cell Using the HX711 with a load cell is a common method for building digital scales or force measurement systems due to its simplicity, low cost, and high precision. The process involves correctly wiring the load cell's four wires to the HX711 board, connecting the board to a microcontroller, using a library, and performing a simple calibration.

The HX711 is purpose-built to interface with Wheatstone bridges, which are the internal circuits of load cells and strain gauges. It provides the necessary excitation voltage to power the bridge and precisely measures the resulting minute differential voltage changes.

Wiring the Components

A standard four-wire load cell uses a color-coded system to identify the wires for excitation voltage and the output signal.

Load Cell to HX711 Connections

Load Cell to HX711 Connections

Connect the load cell wires to the corresponding terminals on the HX711 board:

If you'd like to support the development of the site with the price of a coffee — or a few — please do so here.

Here's a handy tip: you can quickly save this page as a PDF by clicking “export to PDF” in the menu on the right side of the screen.

2026/02/14 22:38

HX711 module board pinout

The HX711 module is a 24-bit ADC meant for weight scales, serving as an interface between a load cell (bridge sensor) and a microcontroller. It usually features two pin sets: one for connecting the load cell (input) and another for the microcontroller (output).

Pin LabelNameDescriptionTypical Wire Colour
E+Excitation PositivePositive supply to the load cell.Red
E-Excitation NegativeGround/Negative supply to the load cell.Black
A-Channel A NegativeNegative differential signal input from the load cell.White
A+Channel A PositivePositive differential signal input from the load cell.Green
B-Channel B NegativeSecondary input channel (lower priority/gain).
B+Channel B PositiveSecondary input channel (lower priority/gain).
VccSupply VoltagePower supply for the module (2.7V to 5.5V).
GNDGroundCommon circuit ground.
DT / DATData OutSerial data output to the microcontroller.
SCK / CLKSerial ClockClock signal input from the microcontroller.

Key Connection Notes

Arduino & HX711

To get started, you'll need the HX711 Arduino Library by bogde, which is the community standard. You can install it directly via the Arduino Library Manager.

Software Setup and Calibration

You will need a library to easily communicate with the HX711 using your microcontroller. The HX711 library by Bogdan Necula is a popular, well-maintained option available in the Arduino Library Manager.

Wiring Diagram

HX711 PinArduino Pin
VCC5V (or 3.3V)
GNDGND
DT (Data)D3
SCK (Clock)D2

Basic Reading & Calibration Code

This script initialises the scale, “tares” it (sets it to zero), and reads the weight.

#include "HX711.h"
 
// Pin definitions
const int LOADCELL_DOUT_PIN = 3;
const int LOADCELL_SCK_PIN = 2;
 
HX711 scale;
 
void setup() {
  Serial.begin(57600);
  Serial.println("Initializing the scale...");
 
  scale.begin(LOADCELL_DOUT_PIN, LOADCELL_SCK_PIN);
 
  // --- CALIBRATION ---
  // 1. Upload this code with scale.set_scale() empty or set to 1.
  // 2. Put a known weight (e.g. 100g) on the scale.
  // 3. Divide the raw reading by the known weight to find this factor.
  scale.set_scale(2280.f);     // Replace 2280.f with your calculated calibration factor
  scale.tare();                // Reset the scale to 0
 
  Serial.println("Scale ready!");
}
 
void loop() {
  if (scale.is_ready()) {
    long reading = scale.get_units(10); // Average of 10 readings
    Serial.print("Weight: ");
    Serial.print(reading);
    Serial.println(" g");
  } else {
    Serial.println("HX711 not found.");
  }
 
  delay(1000);
}

Critical Tips

Sensor topics on lamaPLC

PageDateTags
2026/02/12 22:14, , , , , , , , ,
2026/04/15 13:42, , , , , , , , ,
2026/04/11 14:50, , , , , , , , , ,
2026/04/15 16:59, , , , , , , , ,
2026/02/14 22:31, , , , , , , , , ,
2026/03/21 19:20, , , , , , ,
2026/02/15 20:33, , , , , , , , ,
2026/02/14 23:38, , , , , , , , , , , ,
2026/02/14 22:24, , , , , , , , , , , , ,
2026/03/28 22:50, , , , , , ,
2026/02/15 20:40, , , , , , , , , , , , , ,
2026/02/14 23:36, , , , , , , ,
2026/02/14 23:37, , , , , , , , , , ,
2026/02/14 22:40, , , , , , , , , ,
2026/02/14 22:39, , , , , , , , , , ,
2026/02/14 23:39, , , , , , , , , , , , ,
2026/02/14 22:16, , , , , , , , , , , , ,
2026/03/21 22:25, , , , , , , , , , ,
2026/02/14 22:55, , , , ,
2026/02/14 18:19, , , , , , , , , , ,
2026/02/15 20:42, , , , , , , , ,
2026/02/14 18:11, , , , , , , ,
2026/02/15 20:44, , , , , ,
2025/05/31 21:32, , , , , , , ,
2026/02/14 19:29, , , , , , , , , , , , , ,
2026/03/21 20:45, , , , , , , , ,
2023/07/01 15:29, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
2026/02/14 22:18, , , , , , , , , , , , , , , , , , , ,
2026/03/22 00:26, , , , , , , , ,
2026/02/14 22:19, , , ,
2026/02/14 22:09, , , , , , , , , , , , , , , ,
2026/02/14 21:54, , , , , , , , , , , , , , , , , , , , , , , , ,
2026/02/15 23:59, , , , , , , , , , ,
2026/03/28 18:02, , , , , , , , , , , , , , , , , , ,
2026/02/14 23:58, , , , , , , , , , ,
2026/02/14 23:35, , , , ,
2026/02/14 22:24, , , ,
2026/02/14 23:38, , , , , , ,
2026/02/14 17:38, , , , , , , , , ,
2026/02/15 17:35, , , , , , , , , , ,
2026/02/15 20:20, , , , , , , , , , , , , , , , , ,
2026/03/22 01:24, , , , , , , , , , , ,
2026/02/14 21:17, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
2026/02/15 16:39, , , , , , , ,
2026/02/14 22:23, , , , , , , ,
2025/09/23 16:59, , , , ,
2026/02/14 17:42, , , , , , ,
2026/02/14 22:33, , , , , ,
2026/02/14 22:33, , , , , , , , , , ,
2026/02/15 20:27, , , , , , , , , , , , , , , ,
2026/02/15 20:29, , , , , , , , , , , , , ,
2026/02/15 22:34, , , , , , , , , , , , , , , , , , , , , , , ,
2026/02/14 22:22, , , , , , , , , , , , ,
2023/06/24 22:43, , , , , ,
2026/02/14 22:21, , , , , , , , , , ,
2026/02/14 22:22, , , , , , , ,
2026/02/14 22:32, , , , ,
2026/02/14 23:00, , , , , , , , ,
2026/03/05 20:19, , , , , , , , , , , , , , , , ,
2026/02/14 17:49, , , , , ,
2025/12/10 17:50, , , ,
2025/11/09 17:38, , , , , , , ,


This page has been accessed for: Today: 4, Until now: 218