loading
Picture of Arduino Load Cell / Scale

From the minds at http://arduinotronics.blogspot.com/

Important Update!

Since so many people were having problems with the INA125P, we now have a new and improved version that uses the Hx711 24bit ADC amplifier module. http://arduinotronics.blogspot.com/2015/06/arduino-hx711-digital-scale.html


My goal was to create a programmable scale for weighing objects, parts counting, even directing product flow on a conveyor system.

I needed a load cell, a Arduino, and an amplifier.

Step 1: The Load Cell

Picture of The Load Cell
On this load cell (from a Accuteck  W-8260-86W Postal Scale) the 4 wires coming from the load cell are:

Red: Excitation +
White: Signal +
Green: Signal -
Black: Excitation -

This matches the GSE / NCI / Sensotec wiring scheme.

http://www.controlweigh.com/loadcell_colors.htm
I disconnected the 4 wires from the control board in the scale, so they would be available for the next step.
 
1-40 of 90Next »
Debbie911 month ago

Hi! I am quite new to arduino and loadcells. I am using a 10lbs (4.5kg) loadcell with arduino and the INA125. I connected it as shown however using a 1k ohm resistance and the amplification is too low and I cannot detect a change with the program. How do I determine the gain I need and thus the resistance required?

Thanks!

sspence (author)  Debbie911 month ago
You can get gain information from the data sheet, (6 ohm is a better fit) but I no longer recommend the INA125. The HX711 is much easier to use.

Thanks for the help! I'll try a much lower resistance (after looking at the datasheet I see that 6 ohm would be a much better choice) and I will look into the HX711 as well for future projects!

sspence (author)  Debbie911 month ago

sorry, data sheet url, http://www.ti.com/lit/ds/symlink/ina125.pdf

AnthonyT61 month ago

In sketches, I usually see the pin inputs. I do not see the pins that the code looks at. Am I missing something?

sspence (author)  AnthonyT61 month ago
right in the loop:

int analogValue = analogRead(0);
VishuK2 months ago

hi, I am trying to build a arduino load cell which measures 100kgs. I found this guide very helpful. Can u please assist me in how much resistance and supply from arduino is needed to set the gain which can measure load upto 100kg.

regards!!

hube268.3 months ago

Has anybody gotten this to work with the code provided? I'v tried several times with identical equipment and the readings are garbage even after "calibrating".

sspence (author)  hube268.3 months ago
I did. maybe you are having issues with your amplifier. I have a new amplifier coming that is designed for load cells, will be posting another instructable soon.
hube268. sspence2 months ago

We tried multiple INA125's and it did not make a difference. Three of them to be exact. The INA was amplifying but not nearly enough to make any sort of difference. We tested using highly precise desktop testing equipment and the when we put over 30lbs on the scale the difference with zero was about 0.000001mV. We were also using a very stable benchtop power supply. When we connect the load cell back to the original scale electronics it works great and is able to measure even 2 grams.

I honestly don't believe this tutorial works. Maybe if someone is successful and gets accurate results they can post and provide details of their code and setup.

GerardV hube268.2 months ago

hube268 and I figured out what the issue was and wish to share with everyone else what it was.

The scale we used had the E+ (red wire) and the E- (black wire) connections reversed on the PCB from the factory.

If you look carefully at the picture you'll see the E+ wire is directly coupled with the ground (black wire right next to it).

After discovering this, we switched the black and red wires on our breadboard and it worked as intended.

File Jun 06, 10 27 50 AM.jpeg
sspence (author)  GerardV2 months ago

Awesome!

sspence (author)  hube268.2 months ago

I got the code from http://christian.liljedahl.dk/guides/arduino-and-l...

It worked when I first built this project.

AhmedDjebali3 months ago

Hello Mr.sspence, thanks for sharing your instructable helped me much to understand my scale schema. I bought this scale with 4 load sensors (see the schema) could you please help me, which cables must be connected with the Arduino?

Scale scheam.png
kajitams3 months ago

Hello, thanks for such well written instructions.

I'm getting analog readings all over the place. Any suggestion how I should go about troubleshooting it? I've calibrated as per directions but I'm not getting stable enough readings.
By the way, what should I expect the accuracy of the readings to be? Within 10 grams? I'm using a 7Kg max digital kitchen scale.

hube268.3 months ago
kemalm3 months ago

hi what means by loadA=10kg and loadB=30kg? are those the limit for this coding?

sspence (author)  kemalm3 months ago
Those are weights used to calibrate the scale. Not limits.
kemalm sspence3 months ago
Oh i see..how to calibrate them? Im still newbie in this :/.. can u help me out?
sspence (author)  kemalm3 months ago

As it says right in the code:

// Step 1: Upload this sketch to your arduino board


// You need two loads of well known weight. In this example A = 10 kg. B = 30 kg
// Put on load A
// read the analog value showing (this is analogvalA)
// put on load B
// read the analog value B

// Enter you own analog values here
float loadA = 10; // kg
int analogvalA = 200; // analog reading taken with load A on the load cell

float loadB = 30; // kg
int analogvalB = 600; // analog reading taken with load B on the load cell

// Upload the sketch again, and confirm, that the kilo-reading from the serial output now is correct, using your known loads

sspence (author)  sspence3 months ago
you calibrated with those weights, and wrote down the resulting numbers, then put those numbers in to the code and re uploaded the sketch to the arduino?
kemalm sspence3 months ago
But i use yours example to measure the weight still give same weight..i use two different thing with different weight..so can u help me?
MarcoF53 months ago

Hi Thank you for this instructable it is great. I just put one together and use a load cell i bought online. I just calibrated everything and when I put my first weight and second weight on I get the corresponding right weights but if I put on a weight larger, smaller or in between I get the wrong value. Do you have any insight or suggestions?

VikasS93 months ago

i am stuck....i am getting analog reading as 692 and weight as 3 kgs( without any load).....not getting any other readings....help will be appreciated

sspence (author)  VikasS93 months ago
Did you calibrate the scale?
VikasS9 sspence3 months ago

could you please tell me how exactly could it along with the codes for calibration and the measuring

sspence (author)  VikasS93 months ago

Step 3, read the instructions in the code:

and I quote,

// Step 1: Upload this sketch to your arduino board

// You need two loads of well known weight. In this example A = 10 kg. B = 30 kg
// Put on load A
// read the analog value showing (this is analogvalA)
// put on load B
// read the analog value B

// Enter you own analog values here
float loadA = 10; // kg
int analogvalA = 200; // analog reading taken with load A on the load cell

float loadB = 30; // kg
int analogvalB = 600; // analog reading taken with load B on the load cell

// Upload the sketch again, and confirm, that the kilo-reading from the serial output now is correct, using your known loads

Can I use ina128 instead of ina125?Does it work?

sspence (author)  furkan.gulturk14 months ago
The INA128 uses a dual supply (+/- 2.5v), where the INA125 uses a single supply (+5v), and is therefore easier to use with an arduino.
sspence (author) 4 months ago
yes, just connect your favorite lcd, add the lcd code, and do a lcd.print(weight); to the screen type of thing.
syakm4 months ago

hi sir.

i wanna ask about,if i want to display in a lcd what are the coding part that need to be change or add in order to display the weight in kg. thanks. A.S.A.P

sspence (author)  syakm4 months ago
The units are already in kg.
syakm sspence4 months ago

so basically what i need to do is to connect the circuit with LCD only??

AnthonyT64 months ago

Also, can you shed some light on the sketch?

1. We add the weight to the sketch: float loadA = 5; // kg, for instance I have 11lbs.

2. After entering the weight I make a note of this and then repeat for the second weight

3. I then upload the sketch and then repeat the above to see if the numbers noted are correct

sspence (author)  AnthonyT64 months ago
Did you enter the numbers you got from the first set of measurements into the code?
AnthonyT6 sspence4 months ago

yes, thank you for reminding me.

AnthonyT64 months ago

I have had another chance to look at this circuit. I find three of my cells give one or no resistor reading, thus they are bad. Also while looking at the sketch, If one of my weights is 11 lbs, I would convert that to 5kg and then match the analogValue:

analogvalue = 1024/50 (50kg is my load sensor max) = 20.28 (per kg)

20.28*5 = 101

loadA = 11

analogvalue=101

Does this look correct?

sspence (author)  AnthonyT64 months ago
I'll have to reload that project to be sure, but analog value 1023 would be zero, and analog value 0 would be 50kg, IIRC.
AnthonyT64 months ago

Hi, I have wired up the above several times to assure all pins were correct. I am viewing the display monitor and I find the numbers basically stay the same averaging between analogValue: 13.50 and 13.59. I do not see any changes when weight is applied.without anything on pin one, numbers fluctuate between 18-20. Any ideas why I am not see a change or is it always that little?

sspence (author)  AnthonyT64 months ago
do a serial print of your analogRead, see what the adc is seeing. what value resistor did you add to the amplifier?
1-40 of 90Next »