cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L151VE ADC reads 20% lower value on one of the ADC inputs (channel 18, pin B12)

Pavel Krupets
Associate III

Not sure if I messed something up. Signal is okay (on the pin). No differences with layout compared to other inputs. ADC is at full speed (16 MHz).

On image it is sensor 22 (reads ~2500). Sensor 23, 24, 25 all read normal values (~3000).

Voltages on all those pins is ~2.8V.

VREF, VDDA, VDD = 3.3V.

0690X0000087sCRQAY.png

17 REPLIES 17
MikeDB
Lead

Yes that looks fine. Faulty IC maybe ? Do you have a second PCB loaded ?

Pavel Krupets
Associate III

Checked under stereo microscope (well ones you use for soldering surface mount), didn't see anything suspicious.

Was curious why this stuff can happen, might read it multiple times, it seems 2nd read is better than 1st. Similar to how 1st channel in sequence reads high consistently (10% higher than it should be). This is solved by reading the same channel again immediately after 1st read.

Pavel Krupets
Associate III

Not sure if it is a small defect in a chip. Later will make 2nd version of this board will see if it changes.

MikeDB
Lead

Ok what you could do is set up the code to repeatedly measure just one ADC and measure the current through the VDDA pin. Repeat for the good and bad ADCs and see if there is a significant difference. Means lifting the pin but at least it's not a BGA. Can't think of anything else I'm afraid.

Pavel Krupets
Associate III

I was actually experimenting with using one voltage regulator (switch) to supply all parts (digital and analog) vs using separate linear regulator for analog parts and using voltage reference chip.

Going to make another board with L4 chip as it allows VDDA to be different supply from VDD.

Not sure if I need it though. With one switch DC-DC regulator noise seem to be only +/- 0.35 %. More than enough for my use.

Thank you! Will do! didn't think about this.

MikeDB
Lead

An LC will do on VDDA - shouldn't need a separate regulator

And if that was the problem, all ADCs would be wrong.

Yep. Thank you!

I mean this whole board is test for using simple DC-DC switch regulator. All analog pins have very low noise (checked). Similar to histogram above.