Author Topic: Help wanted: High capacity loadcell with esp32  (Read 2171 times)

0 Members and 1 Guest are viewing this topic.

Offline raoul98765nlTopic starter

  • Newbie
  • Posts: 4
  • Country: nl
Help wanted: High capacity loadcell with esp32
« on: March 03, 2023, 08:49:10 pm »
Hi,

I've got a couple of loadcells I would love to connect to an esp32 to measure the weight of a storage system. I've got 2 times 4 ct50ktc loadcells, 4 per system, specs are 2500mv/v, 5v power, max cap 22500kg.
After some googling I found out that loadcells normally output about 10mv and require an amplifier.
I looked up the formulas for loadcells, and according to the formula the max output voltage of my loadcell is 12.5v. That's a big probleem because the adc on the esp32 has a 3.3v max
. And the loadcell needs a differential adc.
I don't have any experience with loadcells and measuring them. So my question is could anyone help?
« Last Edit: March 04, 2023, 09:39:45 pm by raoul98765nl »
 

Offline Martinn

  • Frequent Contributor
  • **
  • Posts: 304
  • Country: ch
Re: Help wanted: High capacity loadcell with esp32
« Reply #1 on: March 03, 2023, 09:12:33 pm »
The ESP32 ADC is truly miserable, don't use it.
The arduino guys typically use a HX711 type amplifier. Googling "esp32 hx711" will give you plenty of info.
 

Offline Terry Bites

  • Super Contributor
  • ***
  • Posts: 2451
  • Country: gb
  • Recovering Electrical Engineer
Re: Help wanted: High capacity loadcell with esp32
« Reply #2 on: March 03, 2023, 09:45:57 pm »
How are you getting 12.5V from a 5V rail? That sounds like magic to me.
For a load cell excited by 5V you have a common mode voltage of 2.5V.
The term common mode voltage (CMV) refers to the fact that both the + and - outputs of the cell are at the same voltage under no load.
The output, say 10mV, is riding on top of the 2.5V CMV. Its only the difference between + and - you need to amplify.
You need a differential amplifier to sift the precious mV from the CMV. See attched- you'll figure it out.
The HX711 is a handy low cost load cell signal conditioner that will do just that.
Put the HX711 right next to the cell and use data lines to connect to the (remote) micro.
Tip. Buy HX711 ready made PCBs, amazing VFM. You only need one common clock line.
« Last Edit: March 04, 2023, 04:35:16 pm by Terry Bites »
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Help wanted: High capacity loadcell with esp32
« Reply #3 on: March 03, 2023, 09:52:52 pm »
Isn't a load cell a Wheatstone bridge? If so then the 12.5V is probably the maximum voltage it can be safely used at.
 

Offline Terry Bites

  • Super Contributor
  • ***
  • Posts: 2451
  • Country: gb
  • Recovering Electrical Engineer
Re: Help wanted: High capacity loadcell with esp32
« Reply #4 on: March 04, 2023, 04:11:25 pm »
A load cell is most certainly a Wheatstone bridge.
The maximum exitation voltage allowed before heating starts to affect the accuracy of a large cell would be in the >10V area.
Not a good idea to run at the max even if it looks like you're going to get a fatter signal.
 

Offline raoul98765nlTopic starter

  • Newbie
  • Posts: 4
  • Country: nl
Re: Help wanted: High capacity loadcell with esp32
« Reply #5 on: March 04, 2023, 07:58:35 pm »
Thx people for the great feedback.

I initially got the spec from someone onsite, but they do seem a bit off. So, I went to look myself (Picture of loadcell attached), had to clean the label a lot. It seems that the loadcell is 2.5 mv/v so HX711 would work fine.

I've got 2 storage silos, each having 4 loadcells. What would be a recommended way of connecting that? I'm thinking about using the OT3331 (HX711 board)
 

Offline mrburnzie

  • Regular Contributor
  • *
  • Posts: 136
  • Country: cs
Re: Help wanted: High capacity loadcell with esp32
« Reply #6 on: March 04, 2023, 08:10:51 pm »
I had the opportunity to create a bee hive weighing project with the esp32.

In short, I would suggest using an IC like the HX711 or something similar. The esp32 adc is just miserable, and you can't go wrong with a special purpose IC (if in stock of course).
"Talk is cheap, show me the code"

Anyone need of freelance software/hardware developer, hit me up!
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Help wanted: High capacity loadcell with esp32
« Reply #7 on: March 05, 2023, 12:01:14 am »
Thx people for the great feedback.

I initially got the spec from someone onsite, but they do seem a bit off. So, I went to look myself (Picture of loadcell attached), had to clean the label a lot. It seems that the loadcell is 2.5 mv/v so HX711 would work fine.

I've got 2 storage silos, each having 4 loadcells. What would be a recommended way of connecting that? I'm thinking about using the OT3331 (HX711 board)

Do you want the sum of all four load cells in a silo? If that's the case, then it seems what you want is a summing amplifier.

https://www.electronics-tutorials.ws/opamp/opamp_4.html

You have an amplifier for each load cell that gives you a single ended voltage, then you can feed those into the summing amplifier and connect the output of that to the ADC.
 

Offline Terry Bites

  • Super Contributor
  • ***
  • Posts: 2451
  • Country: gb
  • Recovering Electrical Engineer
Re: Help wanted: High capacity loadcell with esp32
« Reply #8 on: March 05, 2023, 11:08:54 am »
Do your summation in the digital domain- the errors will be smaller and easier to calibrate out.
In your harsh envoinment you want to keep the analog electonics and analog signal lines to a minimum.
I'd put a HX711 pcbs very close to the to the cells if you can, feed the clock and data to a local micro that has Ethernet or Wi-Fi.
Say a arduino or Pie.


 

Offline raoul98765nlTopic starter

  • Newbie
  • Posts: 4
  • Country: nl
Re: Help wanted: High capacity loadcell with esp32
« Reply #9 on: March 05, 2023, 07:46:10 pm »
The old system has the load cells cables coiled up and has maybe 5 meters or so of extra cable. After that, all 8 cells are connected in parallel in an ip68 box inside. the bundles 5v+, 5v-, sen+, sen-, gnd are connected to some board named "lcc" which does the measurement and is connect to some proprietary "io-net".
It explains why there could only be one system weight.
I'm planning to use the OT3331 board (HX711 chip with clock and two inputs (A and B)) with an esp32. I'm also planning to only use the included cable from the sensors, so I would place the new system (esp32 + hx711) between the two silos. Or underneath one of the silos to protect against rain.
I have a couple of questions about the parallel connecting:
What happens to the formula?
Does to voltage just add or average?
Is there an easy way to add ethernet to an esp32 devkit board?
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Help wanted: High capacity loadcell with esp32
« Reply #10 on: March 05, 2023, 07:53:17 pm »
ESP32 is a wifi microcontroller, it has no facility to support wired ethernet. If anyone is still making SPI ethernet adapters it's probably possible to make it work but if you aren't going to use WiFi then there is little point in using the ESP32.
 

Offline NiHaoMike

  • Super Contributor
  • ***
  • Posts: 9091
  • Country: us
  • "Don't turn it on - Take it apart!"
    • Facebook Page
Re: Help wanted: High capacity loadcell with esp32
« Reply #11 on: March 06, 2023, 12:34:07 am »
ESP32 is a wifi microcontroller, it has no facility to support wired ethernet.
https://sautter.com/blog/ethernet-on-esp32-using-lan8720/
Cryptocurrency has taught me to love math and at the same time be baffled by it.

Cryptocurrency lesson 0: Altcoins and Bitcoin are not the same thing.
 
The following users thanked this post: james_s

Offline mrburnzie

  • Regular Contributor
  • *
  • Posts: 136
  • Country: cs
Re: Help wanted: High capacity loadcell with esp32
« Reply #12 on: March 06, 2023, 06:42:47 pm »
It supports RMII, thus ethernet is quite easy.
"Talk is cheap, show me the code"

Anyone need of freelance software/hardware developer, hit me up!
 

Offline Martinn

  • Frequent Contributor
  • **
  • Posts: 304
  • Country: ch
Re: Help wanted: High capacity loadcell with esp32
« Reply #13 on: March 06, 2023, 07:57:19 pm »
After that, all 8 cells are connected in parallel in an ip68 box inside. ...
Does to voltage just add or average?
Connecting multiple load cells seems common practise. I have so far been to lazy to do the proper math, but my guess would be that if the cells are perfectly mached (in terms of absolute resistances and sensitivities), then connecting them in parallel would result in having an averaged reading. When sensitivities don't match obviously you will get errors. If you have proper data sheets of your load cells (including measured sensitivities), you could calculate the error. Probably for a silo, distribution on the four corners will be pretty even so most likely connecting four in parallel will be OK (also since you did not state any accuracy requirement).
However I'd definitely use two HX711 for the two silos.

Is there an easy way to add ethernet to an esp32 devkit board?
There is a ethernet devkit https://docs.espressif.com/projects/esp-idf/en/latest/esp32/hw-reference/esp32/get-started-ethernet-kit.html
although ESP32 is known for Wifi, not cabled ethernet, so I wouldn't count on perfect software integration. Why not use a board that has ethernet natively built in like a Raspi?
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Help wanted: High capacity loadcell with esp32
« Reply #14 on: March 07, 2023, 01:03:46 am »
If the load cells were wired in parallel in the original application, and that arrangement provided adequate performance when everything was in good working order then I see no reason why it wouldn't work just as well with a new DIY solution. I suppose you might get potentially useful diagnostic information by being able to view the output from individual load cells though.
 

Offline raoul98765nlTopic starter

  • Newbie
  • Posts: 4
  • Country: nl
Re: Help wanted: High capacity loadcell with esp32
« Reply #15 on: March 07, 2023, 08:06:20 pm »
My thanks to everyone who has replied.

Today I received the hx711 board. Hooked it up to the esp32 and it seems to work fine. I'll connect it to the system in the next few days.

The reason I use the esp32 is because to get the prototype/demo version up and running I'm planning to connect it to an old phone wifi hotspot. But that is a temporary solution. As a permanent solution I was planning to run a 150-meter long ethernet cable/network to the system, but that requires some more paperwork. I'm not sure if ethernet is the best option, but I'm planning to add a couple hundred sensors to the site. The cable runs can get quite large (300-meter max). All sensors send data to a http-server, because of all that ethernet seems like the best option. But I'm open to alternatives.

On the topic of the weight. The old system would drift up and down by about 200kg when it is windy. It's not critically important to know the exact weight, as long as it's not more than 500kg of it's fine. The way I'm planning to calculate the sensitivity and/or scale is by collecting the data for about a week. During that week, the silo would go empty and be filled by a known amount.

On the topic of the hx711. I'll hook up two hx711 boards, one for each silo. The boards are only €0.50 so that isn't a problem.

I've already made the dashboard and cloud backend, so I'm hoping this goes smoothly.

 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf