0
\$\begingroup\$

I've posted very recently about my trouble with load cells. Baffled at how poor my results are. Huge drift to the point that I wouldn't even call it drift. Very noisy readings, too, but I don't know what could be the noise source.

I'm posting again, this time with a simpler, isolated setup:

enter image description here

Here, I have some readings taken shortly after power on.

enter image description here

Here, I have some readings taken maybe two minutes later. I am aware temperature plays an effect, but not like this.

enter image description here

Here is my code. It couldn't be much simpler.

#include "HX711.h"            //https://github.com/bogde/HX711
#include "BufferedOutput.h"   //https://github.com/PowerBroker2/SafeString
// #include "MovingAverageFloat.h"

// HX711 circuit wiring
#define LOADCELL_DOUT_PIN A0
#define LOADCELL_SCK_PIN A2

HX711 scale;
createBufferedOutput(BufferedOut, 80, DROP_UNTIL_EMPTY); //for non-blocking printing

void setup() {
  Serial.begin(9600);
  while(!Serial) {}
  BufferedOut.connect(Serial);
  scale.begin(LOADCELL_DOUT_PIN, LOADCELL_SCK_PIN);
  delay(500);
}

void loop() {
  // if (scale.wait_ready_timeout(500)) { //nonblocking?
  if (scale.is_ready()) BufferedOut.println(scale.read());
  // } 
  delay(500);
}

I've swapped out my ADS1232 strip board module from earlier for Sparkfun's reputable HX711 module. Here is its circuit schematic:

enter image description here

I've grounded the load cell's aluminum body--I've checked that there is continuity. Here is its datasheet: link. 100g load cell because I am looking for 10mg accuracy or better (I found this scholarly article saying they've gotten to 5mg accuracy without temperature compensation and using the same components I'm using, so I'm not being unreasonable with my expectations for the hardware).

I have checked my excitation voltage with an oscilloscope. 100MHz bandwidth, AC coupling. Apparently, 27mV ripple peak-to-peak. Not good. I was expecting a (few) hundred microvolts.

enter image description here

Not sure what else to do here. I know I could order some braided copper sheath for the cables to help with radiative noise, but I consider that a final touch.

I'd really, really appreciate help here. I'm afraid I've reached my limit.

Edit: Load cell impedance between red and black is 1088Ω and between green and white is 1000Ω, in agreement with the datasheet.

Edit 2: I put the thing in a faraday cage.

enter image description here

I removed radiated noise from the equation.

enter image description here

I tried with a different laptop.

I'm just laughing now. Giving it a rest. Need to catch up on other work. Thanks anyways, good people.

\$\endgroup\$
7
  • \$\begingroup\$ What percent deviation of full-scale are those charts? There will always be some small percentage of analog noise; oversampling and averaging is the usual way to defeat it. Two samples per second is too slow - the HX711 could do 80 samples per second; average 80 to give a very flat response. Are you expecting rock-solid microgram resolution out of jellybean plug-n-play "hobbyist" parts? Suggest researching higher-precision designs academically to see how far that engineering rabbit-hole goes (it is quite far.) \$\endgroup\$
    – rdtsc
    Commented Jul 20, 2023 at 12:21
  • \$\begingroup\$ 200000/(2^24)=1.1% Catastrophic deviation. I'll try sampling faster. If I wanted microgram precision, I would be pursuing an EMFC design and would indeed be taking an academic approach. Thanks for the feedback. \$\endgroup\$
    – Popeye
    Commented Jul 20, 2023 at 12:50
  • \$\begingroup\$ The noise floor of your cheapy scope is probably what you’re seeing. You want to measure sub uV values with kiddy toys? The first thing I got was a 6.5digit HP multimeter when I began using load cells. The first thing to realise is that your 24bit adc result is mostly noise. You’ll probably only achieve 14bits of stable data. You want 10mg resolution from a 100g load cell, so thats 1:10000 or between 13 and 14 bits of resolution. Also realise that every dissimilar wire connection is a thermocouple and small temperature differences on the load cell can cause significant drift. \$\endgroup\$
    – Kartman
    Commented Jul 20, 2023 at 13:43
  • \$\begingroup\$ Try powering your system from batteries and avoid any switching power supplies. Make sure there are no draughts of air flowing across the load cell. Touching the load cell may cause drifts. Make a loadcell simulator from a 10turn potentiometer and two resistors so you can test the instrumentation without the load cell. Also note that having your cell phone nearby can cause random perturbations. That alone has caused me to chase my tail many times. As has the 50kW AM radio station 1km away. \$\endgroup\$
    – Kartman
    Commented Jul 20, 2023 at 13:57
  • \$\begingroup\$ You should try "averaging" because of that noise ... (removing almost 8 bits on 24 bits, so minimum 256 samples ...). \$\endgroup\$
    – Antonio51
    Commented Jul 20, 2023 at 14:38

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.