I2C ADC for high precision load cell - Page 1
Forum section: electronics / projects

author: kuon
author_rank: Regular Contributor
timestamp: March 01, 2021, 04:40:17 pm
content: I am working on a medical weigh scale application where I need high precision load cell readings.My load cell is 10V excitation and 2mV/V output (typical wheatstone bridge).The load cell is rated at ±10kg, and I need 1g resolution with 5g max error, the load cell itself is rated at 0.03%, which is 3g max error and if I divide 20mV by 10 000, it is 1uV resolution required.Now there is something else, I need to be able to read the value via I2C. Most ADC I found are SPI. I found some I2C to SPI bridge, but I'd rather use I2C directly. I need a reading every minute.So far, the ADC I selected are MCP3421 and LTC2485.I have two power rails, one 3.3V which is always on, and one 12V which is off when MCU is sleeping. As the ADC and voltage references drawn quite a lot of current, they will be powered by the 12V rail.Now for my questions:- The LTC2485 datasheet mentions an easy drive technology and high gain (up to 256), so I guess I can use it without an amplifier? Do I still need a signal conditioning circuit?- In the MCP3421 datasheet, there is figure 6.9 which is a full signal conditioning circuit reference with 2 amplifier. But in my application, the wheatstone bridge excitation will be 10V and amplifiers and ADC VDD will be 5V (I'll use an I2C level shifter).- Which chip do you think is best?- For power, I plan to use a 10V precision voltage reference for bridge excitation, a precision reference 2.5V for REF+ for the LTC2485 (MCP3421 has reference built in) and a 5V LDO for digital power (ADC, opamp, I2C level shifter). Everything on the 12V rail.I don't have a lot of experience in precision analog circuit, I worked a bit with NFC but I mostly followed reference designs. I know the basis, but for example, in the MCP3421 datasheet, figure 6.9, they use 3kOhm resistors on IN+ and IN- and I don't know where is value is coming from.

author: Kleinstein
author_rank: Super Contributor
timestamp: March 01, 2021, 05:10:26 pm
content: For highest accuracy one should use a kind of AC excitation, e.g. switch the polarity of the excitation.It is possible to work with DC excitation but than has higher demands on the amplification.Amplification would normally be with a low noise instrumentation amplifier, possibly 2 OPs if the ADC has differential input.The amplifier may be more critical than the ADC.The Reference for the ADC and the excitation should be from the same source - no need for a specially stable reference than.The AD3421 is thus not that suitable, as it only works with internal reference.

author: kuon
author_rank: Regular Contributor
timestamp: March 01, 2021, 05:23:39 pm
content: Yeah I found some reference using AC excitation. But most ADC accept max 5V max reference. That's why I thought of using 2 precision references, one 10V for excitation and one lower for ADC reference. Should I just go with 5V excitation while my load cell datasheet mentions 10V?

author: EmmanuelFaure
author_rank: Regular Contributor
timestamp: March 01, 2021, 06:35:43 pm
content: Your I2C criterion is really a bottleneck. There was plenty of integrated solutions using SPI.Use an instrumentation amplifier (Discrete or integrated), plus a medium resolution I2C ADC with software averaging.1g resolution on a 20kg span = 20.000 points = 15 bits. That's not asking for the moon.One example of part selection : LTC2451 ADC (16 bits I2C with REF input to do ratiometric measurements, can work with 3.3V supply) +AD8293G160 instrumentation amp (Fixed gain = 160, can work with 3.3 supply).

author: Kleinstein
author_rank: Super Contributor
timestamp: March 01, 2021, 06:59:46 pm
content: One could still excite the bridge with 10 V, just divide the votlage down, or amplify the ADC ref for the excitation. Even a relative simple divider is usually better than 2 references.1 µV resolution is possible with DC, but not easy. Switching the excitation and thus AC excitation can get higher resolution, but is still not easy.The datasheet for the LTC2440 has an example circuit for AC excitation. For control one could use a small µC, that may also do the SPI-I2C conversion.With 10 V excitation one would likely still power the amplifier also from a relatively high votlage, as the sensor outputs are at some 5 V.

author: kuon
author_rank: Regular Contributor
timestamp: March 01, 2021, 08:16:35 pm
content: Actually, if I drop the requirement for I2C, I can find many more reference designs. Like this:https://www.analog.com/en/design-center/reference-designs/circuits-from-the-lab/cn0155.htmlDo you think I should use an SPI ADC with an I2C to SPI IC, or should I use an I2C ADC with an added signal generator for the excitation as I cannot find I2C ADC with built in excitation?The voltage divider is a very good idea actually, don't know why I didn't think of that.

author: jbb
author_rank: Super Contributor
timestamp: March 01, 2021, 10:04:41 pm
content: I’m by no means an expert, but I would try to integrate as much as possible.As far as I know, it should be OK to use 5V excitation in the bridge (rather than 10V).Then you can get an ADC which accepts 5V analog supply, includes Programmable Gain Amplifier and includes AC excitation mode.If that means you need an I2C to SPI bridge then I think that’s easier than doing all of the bridge drive and signal conditioning yourself.A temperature sensor might also be a good idea. Maybe you could drop an I2C sensor right next to the strain gauge? Or glue it on?Finally, if you’re mounting things remotely you need to look at IO filtering and protection. I2C in particular is a bit delicate and needs special care (or replacement!) if you’re taking it from one board to another with a wire.

author: kuon
author_rank: Regular Contributor
timestamp: March 01, 2021, 10:38:20 pm
content: Yeah, I found many reference designs I can just copy for SPI ADC with PGA and AC excitation, with built in temperature sensor too.The analog front end is actually very close to the load cell (a few centimeters), and then the I2C bus is about 20cm long, but I am not driving it fast, I don't need any speed at all. I also found I2C repeaters if I run into integrity issues.

author: EmmanuelFaure
author_rank: Regular Contributor
timestamp: March 02, 2021, 04:21:12 am
content: Quote from: kuon on March 01, 2021, 08:16:35 pmI guess you don't need many measurements per second. Just bit bang (https://en.wikipedia.org/wiki/Bit_banging) the SPI protocol.

author: kuon
author_rank: Regular Contributor
timestamp: March 02, 2021, 11:04:56 am
content: After looking at many products, I finally settled on the AD7195. Which has everything I need.I should be able to manage the I2C->SPI conversion without problem.

author: David Hess
author_rank: Super Contributor
timestamp: March 02, 2021, 04:02:17 pm
content: Drift and noise of a good instrumentation delta-sigma converter is comparable to low noise precision amplifiers so there is little benefit to using any sort of amplifier before the converter. Load cell output resistance is typically about 350 ohms so buffering should not be needed either.If you build in the capability to reverse the excitation, then thermocouple errors can be removed.Quote from: kuon on March 01, 2021, 04:40:17 pmDo not use separate references. The ADC reference and bridge excitation should use the same reference so that drift and noise in the reference cancels out. Ratiometric conversion like this is so effective that a low noise precision reference will not even be required.

author: kuon
author_rank: Regular Contributor
timestamp: March 02, 2021, 07:06:00 pm
content: I followed your advice and ditched the precision references, after reading more about it, I now understand the ratiometric reference concept. I will also excite the load cell with 5V. So now I have only 5V and 3.3V rails.I ended up with the following.I copied the analog front end filter from the analog design as I don't have any experience with this.I am just not 100% sure of the MIC4427 connection. I connected it to ACX1 and ACX2 as per the AD7195 datasheet, they are out of phase, so if I understand it correctly, it will AB as 00 01 00 10... if A is excitation/ref+, and B is excitation/ref-.As for the I2C->SPI connection, reading the SC18IS602 datasheet, it should be simple enough.

author: Kleinstein
author_rank: Super Contributor
timestamp: March 02, 2021, 08:05:16 pm
content: The capacitor at the AD's reference input is too large. The reference switching does not like much load capacitance. So more like <=1 nF or even without any cap.Similar the other caps (C6 and C8) could be a problem and a bit too large. If needed for EMI suppression I would add some 10 Ohms in series to limit current spikes.I am not sure about using the BPDSW pin instead of GND directly. The MIC4427 shpould be able to turn off the bridge too, so no need for that extra switch in the ADC.I would consider something like a temperaure sensor at the extra inputs.

author: kuon
author_rank: Regular Contributor
timestamp: March 02, 2021, 08:46:12 pm
content: Well, the BPDSW pin is to turn the bridge off from the ADC, but actually, my 5V rail is already switchable (off when main CPU is sleeping). So I guess I don't need it.The ADC has a built in temperature sensor, do you think adding an external one is better?For caps, you mean C6, C7 and C8 to be 1n instead of current values? And 10Ohm resistor on REF± pins?I used this design as reference:

author: jbb
author_rank: Super Contributor
timestamp: March 02, 2021, 09:33:05 pm
content: Like Kleinstein said, I’m not sure switching the ground rail of that H Bridge chip is a good idea.In reference filter: as I understand it, to reject noise you want the same filtering on the ref and input pins.So I suggest you make C6,C7,C8 equal to C3, C4,C5. You’ll also need some resistance between U1 and C7. This should match the input resistance of the analog inputs which is 350R (bridge) plus 100R (R1, R2) so around 450R.Where’s your 5V supply coming from? It doesn’t need to be great, but if it’s got lots of ripple that could impair performance. USB 5V can be a pain; it might range from 5.25V down to 4.4V with up to 0.5V of ripple.If using USB supply, you could consider a 4.1V (or so) linear regulator (so it’s a bit under minimum USB rail). Or some kind of charge pump+linear regulator chip.Also look out for burst mode output from switch mode regulator chips. When load is light, some of them only pulse the power circuit (great for efficiency) but that results in quite a bit of voltage ripple at variable frequency.Long story short: check stuff with an oscilloscope. Multimeters are great but won’t show you a variety of power problems.

author: kuon
author_rank: Regular Contributor
timestamp: March 02, 2021, 10:20:43 pm
content: For 3.3V and 5V, I have two LTC3130, the 3.3V is in automatic burst mode, but the 5V one is forced in PWM mode, and I turn it off when the CPU is sleeping. The whole thing is battery powered, with an LTC4162 managing the battery. I checked my power rails under different conditions and it seems to be quite stable.Should the resistance on the REF be on the left (like R1 and R1) of the cap filter or on the right of it (directly on the ADC pins)?

author: jbb
author_rank: Super Contributor
timestamp: March 02, 2021, 10:39:15 pm
content: Ah, good you’ve got regulated 5V.Capacitors for Ref inputs should be on left hand side, like R1, R2 from the bridge output.

author: kuon
author_rank: Regular Contributor
timestamp: March 02, 2021, 10:59:41 pm
content: I think I fixed everything you suggested.

author: Kleinstein
author_rank: Super Contributor
timestamp: March 02, 2021, 11:14:19 pm
content: There should be no need for the resistors R1 and R2. The bridge as enough resistance of its own.The resistors R4 R5 make sense, though I am not so sure they should be the same as at the input. Those filters at the input and reference are a bit difficult to calculated and may have to be tested in real life. definitely good to have the space (and space to easy solder / unsolder) on the PCB, but not sure if really needed.One may want some extra filtering in the supply to the MIC4427 : when switching, there can be quite some current spikes at the supply.

author: kuon
author_rank: Regular Contributor
timestamp: March 03, 2021, 12:07:56 am
content: Quote from: Kleinstein on March 02, 2021, 11:14:19 pmI will keep the current schematic for testing, and I'll try different resistor values, including 0Ohm for R1/R2 as you suggested.Is 10uf capacitor for the MIC4427 enough or would you consider a higher value?

author: EmmanuelFaure
author_rank: Regular Contributor
timestamp: March 03, 2021, 12:15:19 am
content: Kleinstein is right. A 350 ohm load cell already has a 175 ohm output impedance.

author: kuon
author_rank: Regular Contributor
timestamp: March 03, 2021, 12:00:51 pm
content: Here is my final design.I added some capacitors on the IC, and I'll play with the values of C3-8 and R1,2,4,5. As long as the footprint is here, I can change them.I want to thank you all for your help, it is very appreciated. I will let you know how it performs once completed.

author: jbb
author_rank: Super Contributor
timestamp: March 03, 2021, 09:32:28 pm
content: Ooh, hold on. U3 has a reset pin. Is that an input? If so, check the data sheet for recommendations.If your system design allows, a reset and interrupt line can be very helpful.

author: Kleinstein
author_rank: Super Contributor
timestamp: March 03, 2021, 10:13:38 pm
content: The MIC4427 part may even want some series impedance, the voltage drop from current spikes is mainly limited to the bridge and does not effect the ADC. The ADC would not work directly after switching, but it may still not like the drop, e.g. causing an unstable clock.The reset pin may need some attention - maybe a pull up or the like.

author: voltsandjolts
author_rank: Unknown
timestamp: March 03, 2021, 10:16:34 pm
content: You say this is for a medical weigh scale, so it is likely that it will be used indoors, temperature stable(-ish) environment.If that is the case and you calibrate at room temperature then I'm sure this will be fine.If you need to operate over a wider temperature range, then you might need temperature compensation for SG drift (and calibration at multiple temperatures).In that case you need a temperature sensor close to or in contact with the SG.Better still, if the SG impedance changes a little with temperature, you can use a series resistor to measure actual bridge temperature (on spare ADC channel, single ended maybe acceptable).That works better on silicon SGs of course.

author: kuon
author_rank: Regular Contributor
timestamp: March 03, 2021, 10:59:29 pm
content: Yeah, U3 has a reset pin, but if I want to wire it to the main CPU, I either need to a direct line (and modify all the boards the I2C line transit on, but I explain below why I don't want this) or add another I2C GPIO IC (maybe one with a reset condition on SCL/SDA if this exists). For the RESET pin itself, I checked, it has a built in 10k pull up, I thought this was enough and I hope I did read this correctly as I wanted to test the design and ordered the PCB.I decided to go I2C, because the product has different sensors, and because of its shape, everything is on different boards. They are not far apart (max bus length is 20cm) and 100kHz (or even slower) is fine, but there is 12 PCB in a star topology. With my design, I can just use a single connector with power and I2C lines between boards and have each board evolves on its own, which is very modular.And yes, it will be used inside, so the temperature is stable and it will be automatically re-calibrated on each use. (the system is weighting a cartridge, when the cartridge is removed it take a measurement, and again when the empty cartridge is placed, then examination starts and the cartridge weight will be monitored for a few days).