Dear friends, I am working with stm32f103RBT6 MCU. I have used AMS1117 3.3V regulator both for MCU VDD and also for the VDDA pin. due to noise from GPRS device I need a way to reduce this noise. ADC value is affected about 2% of input value when GPRS is sending or connecting to server. I have a separate power switching regulator for GPRS and have used small signal capacitors as well as ferret beads. I think I should isolate MCU by a DC/DC from power source or use a reference voltage IC for AVDD. Is there any point other than these?
Oops - spelling error by me. Should be band-gap.
It's a special type of zener diode with a very flat curve and it is commonly used as voltage reference. So you might have a processor with 3.3V supply and combine it with a 2.048V voltage reference making a 10-bit ADC measure 2mV/step and a 12-bit ADC measure 0.5mV/step. But there are many possible voltages available.
It's quite common to try to make a cutout in the ground plane so you basically gets two ground planes joined at a single point. One ground plane for the digital functionality and the other for the analog functionality. Then the analog side will be less affected by high currents and high-frequency spikes on the digital section.
And an advantage if you can make use of a ADC voltage reference lower than the supply voltage is that ripple on the supply voltage will get actively filtered by the line regulation of the voltage reference. Add a simple LCR filter and you can get a very stable voltage reference magnitudes better than what you are seeing now.
Many thanks.
regarding my question about ADC accuracy in STM32F103RBT6. I put my board under test with ADC measuring the input voltage on two channels of ADC. after a long time(5 days or more) of operation I find out that the measurement value for a fixed voltage change over time by about few percent!!(same for both channels). any idea?
What component is producing the voltage reference?
If it's the just VCC that is also doubling as the voltage reference for the ADC, then the external voltage from mains and the ambient temperature might result in a quite large drift.
That's why it's best to use a voltage reference explicitly designed for use that use.
unfortunately in the current design I have not used an explicit voltage reference. I used the VCC=3.3V as voltage reference. the board and MCD does not get warm after long operation and also few percent is quite abnormal, isn't it? Can it happen from bad settings for internal ADC registers?
On one hand, all new components ages at a quite grate pace the first weeks in use. You get a "burn in" effect. And it's this effect that is the reason why new devices you buy either fail within the first weeks or potentially works for a great many years.
On the other hand, there can be a quite significant difference in ambient temperature between summer and winter. And that can affect quite a number of components. A vacation month can also make a difference in the load on the local power grid so you can have a couple of percent difference in mains voltage further affecting the temperature of the voltage regulator.
A normal voltage regulator is just a very bad voltage reference for an instrument. And that still leaves any measurement errors from ripple, in case you haven't managed to fully filter away the load-regulation variations in the regulator and the voltage drops in the PCB traces.
In the end, it's all a question of making design decisions - if the goal is to get great measurements then you need to design for that goal. General-purpose solutions can be jack-of-all-trades but then also often a master of none.
Thanks for your points. The measured voltage in my case is a voltage drop over 100ohm resistance. The loop current 4-20mA passes through it. I think the resistance change with ambient temperature. The resistance I used has 2% to 5% tolerance which operates in -55 to 155 C degrees. but I calibrated using coefficients in my program. It seems it may happen that the resistance change with ambient temperature. so that it cause error in measurement even 1% fluctuation of resistance is a big problem.
What type of resistor?
Metal film or some other variant?
And what power rating? How much does the resistor heat up at 20mA current?
Maybe you should add a temperature sensor, allowing you to create a calibration curve over the full expected temperature range.
But if 1% is a problem then I think you should do a full review of the design, so all critical components have well defined parameters over the full operating range of temperatures, voltages, ...
I used Carbon Film 1/4 Watt Resistor. At 20 mA it does not heat up or it was not sensible for me. I have also used a 100nF SMD Multilayer Ceramic Capacitor size 1210 in parallel with the resistor to filter high frequency noise or signals on 4-20mA communication lines.
I thought most people had left carbon film resistors except for special applications, such as if you need high pulse stability.
Have a quick look at: www.resistorguide.com/.../
Your carbon film resistors aren't exactly at the top when it comes to stability. They age faster and are more affected by temperature than metal film or metal oxide resistors.
And for measurement instruments, there are even better choices available - such as metal foil resistors - even if lots of measurements don't need that quality level.
See also the table in this article: www.eetimes.com/document.asp
Thank you very much. Surely I have to change the resistor type. I find the right resistor by reviewing such differences.