• AVR Freaks

Helpful Replydspic33E voltage reference

Author
Javier Lopez
Pulsotron designer
  • Total Posts : 44
  • Reward points : 0
  • Joined: 2019/02/27 09:59:32
  • Location: Spain
  • Status: offline
2019/05/22 02:05:35 (permalink)
0

dspic33E voltage reference

I have attached the AVdd to general 3.3V supply that is an error due it vary too much (I should use a separate power), so how can I acquire internal voltage reference to correct the problem by software?, I have read that there is a 32 levels reference but I do not find how to set the multiplexer to acquire it
#1
JPortici
Super Member
  • Total Posts : 674
  • Reward points : 0
  • Joined: 2012/11/17 06:27:45
  • Location: Grappaland
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 02:53:49 (permalink)
0
who knows? You don't say which dsPIC. There is at least a different answer for every family
write the complete part number
#2
Javier Lopez
Pulsotron designer
  • Total Posts : 44
  • Reward points : 0
  • Joined: 2019/02/27 09:59:32
  • Location: Spain
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 04:38:18 (permalink)
0
It is a dspic33ep128GM604, I have look at the diagram of the ADC and not find any connection through any multiplexer to an internal reference. 
#3
JPortici
Super Member
  • Total Posts : 674
  • Reward points : 0
  • Joined: 2012/11/17 06:27:45
  • Location: Grappaland
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 04:50:45 (permalink) ☄ Helpfulby Javier Lopez 2019/05/22 06:29:41
5 (1)
Because there is no internal voltage reference.
Keep on reading, the table for VCFG values shows that you can use AVDD/VREF+ for positive reference and AVSS/VREF for negative reference, in different combinations.
 
Then, as it's mentioned at the beginning of the datasheet
70000689d.pdfUp to Four Op Amp/Comparators with Direct Connection to the ADC module:
- Additional dedicated comparator
- Programmable references with 32 voltage points
- Programmable blanking and filtering

 
the voltage reference with 32 levels is for the comparator only (CVREF) and, as the OP AMP/COMPARATOR VOLTAGE REFERENCE BLOCK DIAGRAM will tell you, CVREF is derivated from either AVDD or VREF+.
 
if you want an external voltage reference you'll have to use VREF+ (No need to use VREF-)
otherwise, fix your board layout
-a small resistor,inductor or ferrite bead (chosen with some criteria) between the main VDD and AVDD and decoupling caps between AVDD/AVSS.
-small capacitors next to the analog inputs to decouple the signal (that will reduce the bandwidth of the signal)
#4
Javier Lopez
Pulsotron designer
  • Total Posts : 44
  • Reward points : 0
  • Joined: 2019/02/27 09:59:32
  • Location: Spain
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 06:29:37 (permalink)
0
OK, thank you. I have read that there are LDO voltage regulators like LM3940-3.3 that changes 35mV/amp, so connecting such LDO to AVdd alone that drains 5mA I suppose there will be very low error.  
#5
JPortici
Super Member
  • Total Posts : 674
  • Reward points : 0
  • Joined: 2012/11/17 06:27:45
  • Location: Grappaland
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 07:53:59 (permalink)
0
That sounds crazy high to me, unless you have low impedance loads on all the opamp/comparators outputs.
#6
Javier Lopez
Pulsotron designer
  • Total Posts : 44
  • Reward points : 0
  • Joined: 2019/02/27 09:59:32
  • Location: Spain
  • Status: offline
Re: dspic33E voltage reference 2019/05/22 08:05:50 (permalink)
0
May be but it is more crazy to me to look for a way to remove a signal pin and give pcb surface to place an external vref when all the legs but one are used and all area surrounding the micro si full of components. Any way I will use only micros that have internal voltage reference when using its adc. 
post edited by Javier Lopez - 2019/05/22 08:08:07
#7
JPortici
Super Member
  • Total Posts : 674
  • Reward points : 0
  • Joined: 2012/11/17 06:27:45
  • Location: Grappaland
  • Status: offline
Re: dspic33E voltage reference 2019/05/23 00:21:24 (permalink)
0
another very bad idea. Unless you pick a (expensive/specialized) part with an accurate reference, Internal voltage references are notoriously poor references. They are needed inside the chip for the oscillator and things like that which need a bias voltage, so they don't have to be accurate and/or low drift.
 
they have their use but once you account for the poor specs, using AVDD is usually the best choice if you don't have the space/budget for an external reference.
 
I am positive that this is an hardware issue, like wrong layout or wrong choice of components. You should attempt to fix your current hardware because i am positive that this is purely an hardware issue, so more decoupling, filtering on both AVDD and the analog inputs. This forum and the internet is full on material on how to diagnose and solve the issue of fluctuating analog inputs
#8
Javier Lopez
Pulsotron designer
  • Total Posts : 44
  • Reward points : 0
  • Joined: 2019/02/27 09:59:32
  • Location: Spain
  • Status: offline
Re: dspic33E voltage reference 2019/05/27 23:54:31 (permalink)
0
There are some very accurate voltage references that can supply the 4mA of the AVdd and also accurate voltage regulators but as it is said by JPortici is better to use the voltage reference. Also it is possible to use one of that ADC line to acquire an external reference (1.2V) and make the correction by using software
#9
Jump to:
© 2019 APG vNext Commercial Version 4.5