14.4V ground reference for ADC - Page 1
Forum section: electronics / projects

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 18, 2019, 03:08:00 pm
content: I am designing a precision bench power supply(18V 1A).I am using an 18 bit ADC (MCP3421) to measure current across a 1current shunt(I know 18 bit is too precise but it was the cheapest one i can get because its sampling rate was 4.5 Samples / second.But its common mode input voltage range was way too low for me to use it.So i decided to use this circuit so i can use this ADC.What i did is i rather than connecting the GND of the ADC to GND, I used an 14.4V (max. common mode input voltage range was (VDD+0.3) 5.8V. So 18V-14.4V =3.6V)voltage follower circuit so the max vdd and common mode input voltage range is under the limit of the ADC.And used an isolater (SI8602) to transmit the data to the microcontroller.Will this circuit work?

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 02:25:34 pm
content: This sounds over complicated. What you should do as you are in the business of throwing stuff at this just to use this ADC is use a current sensing chip. This can also be done with an opamp but there are lots of nice solutions out there that allow you to measure the voltage drop in a high side sense resistor and get a corresponding voltage out referenced to ground. These also amplify your current sensed voltage allowing you to use milli ohms of sensing resistor. Your 1 ohm resistor will waste 1W when you output 1A, at full 18V that is 5.5% wasted power just in your measurement and as you valtage falls it only get worse. at 5V/1A that is a 20% loss. also it means that your regulator which needs to take feedback from after the resistor will have even more work to do as just pulling more current will cause significant voltage variation in the supply itselfIf you use a current sense amp you can have a gain of up to 100 with great precision meaning you only need 10mR and will waste 1/100th the power. At 1A flow you will waste 10mW with a loss of 0.0555% at 18V/1A.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 02:35:34 pm
content: yeah it might be a good solution but i already ordered this ADC.Please let me know if this circuit will work.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 02:40:51 pm
content: No it won't because your ADC ground will be above the µC one. The problem is not the ADC but how you are trying to use it. It is easier to keep everything referenced to ground. You need to use something like a INA225EVM from Texas Instruments.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 03:17:43 pm
content: I will use an isolater to transmit data to the microcontroller.The adc side ground will be connected to the 14.4V GND and the microcontroller side will be connected to real GND.Will it work??

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 03:25:26 pm
content: I am using Si8602 as an isolater.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 03:34:50 pm
content: Theoretically yes, but it's still a stupid way to do it but go right ahead and make life hard for yourself. It has nothing to do with the ADC, every ADC will have this problem. The name of your problem is "high side current measurement" not "how to float an ADC". How do you think everyone else does it?

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 03:36:11 pm
content: where is the positive supply coming from for the ADC, where is the positive reference voltage for the ADC?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 03:39:30 pm
content: Positive voltage of the adc is the 18V supply for the whole psu.This ADC is internally referenced to 2.048V

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 03:46:49 pm
content: Yes it's stupid to do this.But I am building this psu on a tight budget .So I need to do this.The current sense amp you said is the right waybut my online store RS components have it but the minimum quantity is 5.As I said I am on a tight budget.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 03:52:22 pm
content: You are on a tight budget but you are making it expensive for yourself. You are using 2 chips instead of 1. the opamp to create the ground reference and the isolator. Isolators are not cheap but it's your money you are throwing away. Learn this, engineering done to silly budget constarints at best just fails and at worse kills people. You do not have to use the current sense chip I suggested, there are loads of them and many cheaper than the TI one. If you think a programmer can design power electronics and signal processing then think again!Learn about the building blocks and use them. Don't do the wrong solution just begcause it is the only one you know.Let me guess, does the voltage regulation happen in the microcontroller by any chance?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 04:03:52 pm
content: The voltage regulation is done using a DAC which is controlled by a MCU.I will take your words for my next project because I have really done a dumb thing I already ordered the adc and isolaterdon't worry about the opamp it's just an lm358.Thanks for your reply.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 04:37:33 pm
content: That won't work. A µC is too slow to react to load changes plus the conversion and communication time of the ADC. Contrary to what youtube channels like Great Scott say using a microcontroller inside such a critically fast control loop does not work.You could even use the LM358 to measure you current sense resistor now that you have it but specific chips for this job which are essentially a special purpose opamp cost pence/cents.So what type of voltage regulator is this? what is doing the power control?

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 04:38:26 pm
content: You could also use the LM358 to do the voltage regulation.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 04:52:46 pm
content: You can use digital stuff to monitor the regulator and give YOU feedback but not the main regulation loop.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 05:15:30 pm
content: Here is the circuit i am using to regulate voltage and controlling the current.Please have a look at it and if you spot any error please notify me.The dumb thing about this is I don't need that precise 12 bit DAC .But i just used it because it is under my budget.Because Dave used it in his microsupply(REV A).So i was sure it will work and I don't haveto respin the pcb.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 05:20:06 pm
content: dont mind that i am new to this forum and i haven't written anything like this in any forum or anywhere in my life.So expect some errors.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 05:29:35 pm
content: where is the schematic from? where is the µC and ADC?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 19, 2019, 05:34:55 pm
content: All schematic I posted are part of the same schematic.I am just posting it like this because if you have to look at something you have to zoom in and the resolution might be too low. ADC MCU DAC LDO are all in the same schematic.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 06:06:42 pm
content: Well there is already a current sense circuit there, you just need to connect your ADC input to that. You have an independant voltage regulator LT3080 so I'm not sure what your trying to do.

author: Zero999
author_rank: Super Contributor
timestamp: May 19, 2019, 06:51:56 pm
content: Quote from: Simon on May 19, 2019, 04:37:33 pmThe problem with the LM358 is its common mode range does not extend to its positive rail.An op-amp with inputs which do work up to the positive supply can be used with a transistor to amplify and level shift the signal to the 0V rail.https://www.analog.com/en/analog-dialogue/articles/high-side-current-sensing-wide-dynamic-range.html

author: wraper
author_rank: Unknown
timestamp: May 19, 2019, 07:02:51 pm
content: Quote from: Simon on May 19, 2019, 04:37:33 pmIt can work and can show great results. However not just general purpose MCU and it will be very tricky.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 07:08:15 pm
content: Quote from: Zero999 on May 19, 2019, 06:51:56 pmYea, it can only go to within 1.5V of the positive rail so a voltage divider would be required each side. You loose a small bit of the 1V range but it can be made to work on the budget. there is already a current sense in the circuit that can be used for what the OP wants.

author: wraper
author_rank: Unknown
timestamp: May 19, 2019, 07:12:53 pm
content: Quote from: Arjunan M R on May 19, 2019, 05:15:30 pmIt is non functional. For example becauseallopamps are powered from 5V. EDIT: Nope,not all(point stands) powered from 5V but why in the hell would you note +18 V as VCC?.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 07:15:58 pm
content: hahaha, i had not noticed. I say again to the OP, if your a programmer start on something simpler......

author: Zero999
author_rank: Super Contributor
timestamp: May 19, 2019, 07:44:43 pm
content: Quote from: Simon on May 19, 2019, 07:08:15 pmYes, but accuracy will be poor.Another option would be to use an op-amp with P-JFET inputs, which will work up to the positive rail and be fine with a total supply voltage of over 15V, thus eliminating the zener diode. The trouble is cheap P-JFET op-amps tend to have a fairly high offset error: 3mV for the TL082, although that can be nulled out. Further cost cutting could be achieved by using a BJT, rather than a MOSFET, at the expense of reduced accuracy, although that could be mitigated somewhat by using one with a high hFE, such as the BC560C.

author: Simon
author_rank: Unknown
timestamp: May 19, 2019, 08:03:15 pm
content: Oh I am sure there are more suitable parts than the LM358, i was just trying to explain that what he is trying to do is far harder work that using what he already has to do something better. He wants to drop up to 1V on the shunt resistor, 1.5V on 18V does not require too much of a loss in that range. The circuit he has posted already has a current shunt amplifier. To be honest i am confused as to what he is trying to do here.

author: Zero999
author_rank: Super Contributor
timestamp: May 19, 2019, 10:02:48 pm
content: Oh, I think I know what you meant now. Were you talking about the standard differential amplifier configuration?https://en.wikipedia.org/wiki/Differential_amplifier#Operational_amplifier_as_differential_amplifierYes, that should work well enough, as long as a the resistors are fairly well matched and the gain isn't too high, so the inputs remain within the common mode range of the amplifier. The voltage across R1 and R2 must be under 1.5V, which would limit the gain to a maximum of (18-1.5)/1.5 = 11, with a supply voltage of 18V, but at lower supply voltages, the maximum gain will be less.Another issue with the LM358 is it doesn't have a true negative rail output. Its output is pulled low by a current sink and will not go near 0V, unless the output is sinking a tiny current, so R1 + RF will need to be quite large: over 1M for <18μA of output current sunk would be ideal.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:09:29 am
content: Quote from: wraper on May 19, 2019, 07:12:53 pm+18V is regulated to +5V using L7805.Because +18V is the common supply voltage for everything in this schematic I noted +18V as VCC as I said this is not the full schematic.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:16:36 am
content: Quote from: Simon on May 19, 2019, 06:06:42 pmYes you are right.I will change the circuit.I will connect the ADC input to the current sense amp output so i can get rid of that 14.4V GND REF.It was a differential ADC so I thought i can just measure across that shunt.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:18:12 am
content: If i do that I can get rid of that 1and go to milliohms.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:24:14 am
content: Quote from: Simon on May 19, 2019, 08:03:15 pmYes you are right I am over complicating everything myself.I will measure the output of the current sense amp using ADC so i can get rid of that GND REF.If i do that i can use shunt with lower resistance.So higher efficiency.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:33:47 am
content: Quote from: Simon on May 19, 2019, 07:15:58 pmYes i need to start on something simpler.But I decided to built this because i don't have a PSU and i needed one and i thought i can build one myself.Yes there are cheaper PSU s than my whole project costs and with more power(mine is only 18W) but they don't have that much precision.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:45:20 am
content: Here is the full schematic.Note that i recently changed the MCU and didn't connect all the connections.I have made some changes now.Written on black is net labels.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:47:22 am
content: Here is the image of the full schematic.

author: wraper
author_rank: Unknown
timestamp: May 20, 2019, 03:54:58 am
content: Quote from: Arjunan M R on May 20, 2019, 03:09:29 amVCC is not common voltage. It literally means "Voltage Collector Collector" and was used for describing positive supply of logic/digital ICs. Modern digital ICs no longer use BJT transistors but MOSFETs so it became VDD (Voltage Drain Drain) but VCC is still commonly used along with latter. Naming 18V supply as VCC is counterproductive, especially if other people will see your circuits.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 04:00:38 am
content: Quote from: wraper on May 20, 2019, 03:54:58 amSorry I don't know that.so I will rename 18V as +18V and 5V as VCC

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 05:44:51 am
content: The nice thing about the current sense amp(LT6105) is that its common mode input voltage can be higherthan its supply voltage.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 06:05:01 am
content: Right I decided to use a 100m25W 1% current shunt.

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 06:28:25 am
content: Quote from: Arjunan M R on May 20, 2019, 05:44:51 amThat is the whole point of using a current sensing amp like I was trying to explain. While they are opamps they are specifically designed to do this will do what a regular opamp will not.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 06:30:35 am
content: Quote from: Simon on May 20, 2019, 06:28:25 am

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 06:33:49 am
content: Quote from: Arjunan M R on May 20, 2019, 03:33:47 amYou have the LT3080 regulator in your schematic. that is all you need for a basic PSU.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 06:36:38 am
content: Quote from: Simon on May 20, 2019, 06:33:49 amI dont want just voltage regulation i also want constant current output to make sure my circuits don't blow up as i constantly makes mistakes

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 06:59:31 am
content: Well.... you have the current sense amp and the LM358. i am not an opamp wiz but I think that if you connect the LM358 as a non inverting opamp with a little gain I think so that at full voltage drop on the sense resistor for 1A you have 18V out. Then connect a potentiometer to the inverting input of the LM358 so that you control the offset. Then connect the voltage setting resistor of the LT3080 to the output of the LM358 instead of ground. This way solong as the voltage from the current sense amplifier is less than the voltage on the inverting input to the LM358 the output of the LM328 will pull the voltage setting resistor to ground allowing full voltage. As the current rises and the voltage from the current sense amp increases above the set threshold on the -input of the LM358 the output of the LM358 will rise which will reduce the current in the voltage setting resistor of the LT3080 because there is less voltage difference across it and the voltage will "fold" to maintain the current.Your valtage regulation will change by putting the LM358 into the voltage setting because it has some voltage dro so you need to experiment.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 07:10:28 am
content: Quote from: Simon on May 20, 2019, 06:59:31 amNo i am not doing it this way i am using a rotary encoder to set both voltage and current thats the main purpose of MCU . Using a pot. you cant accurately set the current. In my circuit i also have an lcd to display set and out I and V.And an opamp to set the current like shown in the schematic.The non inverting input of the opamp will be connected to output of the current sense amp and inverting input to the DAC(MCP4922 has 2 channels).So I can set the current using the DAC.Note that i recently changed the MCU and didn't connect it

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 07:41:47 am
content: Well you can still do the current limit my way just use a low pass filtereid PWM to set the threshold voltage. I fact you can also do the same to the mosfet you are controlling to control the voltage setting or your DAC. But like I say you just want to get going so keep it simple first.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 09:09:54 am
content: Quote from: Simon on May 20, 2019, 07:41:47 amI don't want to go in trouble finding the value of the capacitor and resistor and the pwm frequency of the MCU. I will stick with DAC . It will be much more simpler for me.

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 11:41:27 am
content: Quote from: Arjunan M R on May 20, 2019, 09:09:54 amIf you can't do that then you are wasting your time with electronics, it's a free DAC and you are budget constrained yet you are using all of the over the top expensive solutions. What you want to do is feasible provided you do not put anything digihal in a regulation feedback loop. Current limiting you may get away with but there will be a delay.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 12:07:42 pm
content: Quote from: Simon on May 20, 2019, 11:41:27 amI can use a PWM but is there any advatage over a DAC (because i already ordered it)Mainly i am concerned with PWM because i don't have a scope to see the output of the DAC .So if any issues were foundi can't fix it thats why i said i will stick with DAC. What delay are you talking about.The DAC is just setting the voltage at the inverting input of the opamp. The DAC's output will only change when we set the current. It doesnt change when the max. current limit is reached.When the max current limit is reached the output of the current limit opamp will go high and the mosfet will turn on and it will pull the set pin to ground.The DAC is not in the feedback loop.So i don't expect any delay.This is the feedback loop i think

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 12:09:40 pm
content: Then how is the DAC on the feedback loop

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 02:06:08 pm
content: Oops, a mistake int the circuit.I connected the input of the opamp in reverse

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 02:11:10 pm
content: Quote from: Simon on May 20, 2019, 11:41:27 amIts a good idea especially if you are designing a psu with higher power rating.I will do this in my next psu project which will be more cheaperbecause it will be high power and low accuracy

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 03:34:00 pm
content: I was refering to your current limits. This is usually done in analogue so reacts instantly. There are smart mosfets that will cut out in 1µs if overloaded. if the current limit does not react fast enough it can still damage stuff.PWM DAC is easy. the output voltage will be the averaged PWM value, you use a low pass filter that has a cut off frequency 10-100 times lower than the PWM, simple matter of physics.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:37:06 pm
content: Quote from: Simon on May 20, 2019, 03:34:00 pmCan you tell me a part number of any of that smart mosfets?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:41:39 pm
content: I was trying to get rid of that atmega644 and use arduino uno ((atmega328p) which i already have) so i can get the cost down.I am trying to put as many things as possible in the I2C.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:48:21 pm
content: Quote from: Simon on May 20, 2019, 03:34:00 pmYes when i simulated the circuit in lt spice i saw a big current spike eventhough i set the constant current.It was lower than 1ms so i thought it doesn't matter.Now i think it does matter.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:51:00 pm
content: Quote from: Simon on May 20, 2019, 03:34:00 pmDoes adding an inductor before the current shunt help??

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 20, 2019, 03:52:47 pm
content: Quote from: Simon on May 20, 2019, 03:34:00 pmWhat can i do about it. I still need to use the DAC.

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 05:11:06 pm
content: Quote from: Arjunan M R on May 20, 2019, 03:51:00 pmNO!

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 05:12:48 pm
content: Quote from: Arjunan M R on May 20, 2019, 03:52:47 pmYou could learn what you are doing before making stuff up. You have done nothing but emphasize the cost has to be low yet you have thrown parts at this like there is no tomorrow. Why not do the simpler design first that you talked about.

author: Simon
author_rank: Unknown
timestamp: May 20, 2019, 05:15:59 pm
content: Quote from: Arjunan M R on May 20, 2019, 03:37:06 pmNo I don't. Look them up yourself and learn about them before throwing them around. a smart mosfet datasheet can be 50 pages long. a smart mosfet is not what you want. for example an Infineon mosfet rated for 10A will not cut out through over current for over 50A.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 03:56:12 am
content: Quote from: Simon on May 20, 2019, 05:12:48 pmI have already done a simpler one a 2 channel PSU with one channel using LM317(1.25-12V)and another with (1-44V) using buck and boost convereter . And with maximum current(two channels)900mA.It has no current limit.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 03:57:12 am
content: Quote from: Simon on May 20, 2019, 05:12:48 pmYeah, thats my problem

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 04:12:43 am
content: I don't understand what you are talking about mosfet

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 05:05:50 am
content: The output setling time of the current sense amp is 5µs..And the risetime+ turn on delay time of the irfz44n is only 72ns. and the settling time of the opamp i am using is 1.1µs. So total delay of 6.172µs.Is that a big delay??

author: Simon
author_rank: Unknown
timestamp: May 21, 2019, 06:27:56 am
content: What sort of current limit do you want? you can cut out completely or foldback. For foldback just look it up, there is lots online about it. For cutout you would need a comparator and a latch I think, not something i have done before myself.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 06:32:05 am
content: Quote from: Simon on May 21, 2019, 06:27:56 amI want foldback current limiting

author: Simon
author_rank: Unknown
timestamp: May 21, 2019, 06:35:05 am
content: Foldback is easy with SMPS, just measure the current and if you trip a threshold blank the gate drive to the switching element.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 06:38:36 am
content: Quote from: Simon on May 21, 2019, 06:35:05 amI don't understand what you mean by blank the gate drive.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 21, 2019, 06:42:11 am
content: Quote from: Simon on May 21, 2019, 06:35:05 amI am not going to change the specifications I choose for the psu.(linear,18V,1A)

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:22:32 am
content: Hi, I am going to change the voltage reference(2.048V) of my DAC(mcp4922) from ISL21080 to REF3120.I looked at the datasheet and it seems good enoughfor my purpose.Note that the DAC voltage ref input is unbuffered.Is there any problem using this v.ref.?Here is thedatasheetplease have a look at it.

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:30:38 am
content: Your link is brocken, but what you do is look at the output current of the voltage reference in it's datasheet and then look up the input current to the voltage reference pin in the datasheet for the DAC.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:32:19 am
content: Quote from: Simon on May 30, 2019, 06:30:38 amNo it is working.When you click on it it will automatically download the pdf file

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:32:58 am
content: Quote from: Simon on May 30, 2019, 06:30:38 amOk

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:35:17 am
content: Quote from: Arjunan M R on May 30, 2019, 06:32:19 amNo it was brocken and you just edited it! If that is your attitude good luck learninig electronics. Maybe you want to try lego bricks where everything is made for each other and nothing can go wrong!

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:37:16 am
content: Your reference outputs 10mA, I doubt any DAC input wants moro than that. read carefully any notes about the output capacitor value and type required.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:38:39 am
content: I was looking at the datasheet and it says input vref impeadance = 165KΩ So 2.048/165K = 12.412µA

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:39:21 am
content: of the dac

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:40:04 am
content: so it will be ok

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:41:23 am
content: OK so now just make sure you setup the reference correctly. read the whole datasheet and make sure you pick up on any requirements for your application.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:43:09 am
content: The DAC has a buffered modeI didn't read the datasheet carefully

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:50:33 am
content: Check your frequency response. Sounds like unbuffered is better and you certainly have the drive for it.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:52:49 am
content: Quote from: Simon on May 30, 2019, 06:50:33 amyeah, i will go with the unbuffered mode because it draws very low current and i don't have to overcomplicate the code for no reason.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 06:55:19 am
content: I don't understand by checking freaquency response, of the DAC or VREF.Sorry i don't know what it meansIs it this?

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 06:58:10 am
content: what is that a graph of? the reference or the DAC?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:01:42 am
content: What is this?20 V peak to peak

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:02:22 am
content: Quote from: Simon on May 30, 2019, 06:58:10 amIt is the Voltage reference

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:09:08 am
content: Quote from: Arjunan M R on May 30, 2019, 07:01:42 amI think its 10mV/div

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:15:31 am
content: Quote from: Simon on May 30, 2019, 06:35:17 amSorry it was a mistake i was trying to add a hyperlink, and i was editing what i posted when you replied.I didn't know how to add a hyperlink.That's why the link is broken

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:17:21 am
content: What can i do about the noise?Any circuit?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:21:10 am
content: Found something from TIHere it is

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:31:03 am
content: But it requires a precision opamp

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:36:25 am
content: Is this enough a 10µF tantulum and 100nF ceramic cap on the output??

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 07:44:07 am
content: Found this on the datasheet of the VREF.Is this enough for filtering??

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 09:42:04 am
content: But look what it says on the electrical characteristics.I think it is 10µV/div

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 09:54:16 am
content: So i think i will stick with this voltage reference.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 10:09:06 am
content: Quote from: Simon on May 30, 2019, 06:37:16 amREF 3120 does not require a output bypass capacitor.Only a supply bypass of more than 0.47µF.I am going to still add a 10µF tantulum and 100nF ceramic cap to input and output for extra stability and noise reduction.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 10:15:15 am
content: IT requires a 100nF cap. for supply bypass.

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 11:47:50 am
content: Yes just follow the datasheets recomendations. You are drawing µA not mA so you don't need to go heavy handed on the output capacitance. Filtering it is not a bad idea.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 11:50:05 am
content: Quote from: Simon on May 30, 2019, 11:47:50 amSo i will put only a 100nF bypass cap at the output.

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 11:52:00 am
content: That will probably be enough.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 11:56:13 am
content: one question, the datasheet of the vref says to put a low esr ceramic cap at the supply input for bypassing.Do i need to care aboutlow esr??

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 12:00:35 pm
content: Yes ESR is very important. A real capaocitor is modelled in a theory by a perfect capacitor with a resistor in series. this resistor is the ESR. Equivalent series resistor. If your ESR is high it slows the capacitors response to demand. This is why often you see an electrolytic with a ceramic in parallel because the ceramic has near 0 ESR but they are not large and bigger ones are expensive, so a compromise is made with enough capacity helped by some fast acting capacitance.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 12:18:58 pm
content: here is thedatasheetof the capacitor i am using.I ca't find any values for ESR in it.Please have a look at it.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 12:33:05 pm
content: Is this the ESR?

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 12:52:19 pm
content: If it's a ceramic it's low ESR, ESR is a problem for electrolytics or niche applications with ceramic.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 12:54:52 pm
content: Quote from: Simon on May 30, 2019, 12:52:19 pmSo what are the parameters i need to look when selecting the ceramic capacitor rather than voltage and capacitance

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 03:32:31 pm
content: The dialectric is an indicator of the capacitors quality and tolerance. The best is X7R, the next best is X7S. All ceramics will have good enough low ESR for what you want unless you are dabling with EMC which you are not here.

author: Siwastaja
author_rank: Super Contributor
timestamp: May 30, 2019, 03:46:42 pm
content: Standard ceramic capacitor all have very low ESR, the lowest you can get practically. For a typical 0805 size, it's roughly around 10 milliohms. Compare this to around 5-10 ohms, three orders of magnitude more, for similar capacitance electrolytics, tantalum or aluminium. It's often not specified, as it's irrelevant whether it's 0, 10 or 20 mOhm, it can be approximated zero in 99% of the cases. Note that ESR has both good and bad sides to it, sometimes you want to minimize it, sometimes you absolutely need it.The most important single parameter for ceramic capacitors isactual capacitance versus DC bias voltagecharacteristic. This is widely misunderstood subject. Opposite to common misbelief, you can't reliably deduce this characteristic from the dielectric type (unless it's C0G/NP0); you need the actual data from the manufacturer. Sometimes the spec doesn't exist; if the actual capacitance value matters at all, ignore such capacitors. It's fair to expect it can go down to 10% of the rated C, even for "good" X7R type caps.A further complication is that often the datasheets that instruct you to use a, say, 4.7uF capacitor, already assume you use such a capacitor type with poor DC bias characteristics, but fail to tell you how much actual capacitance theyactuallyrequire. So requiring "4.7uF ceramic" in a datasheet can mean less than 1uF actually, but it can mean 2uF as well, so you need to guess, or play safe and use a bigger package with known good DC bias characteristics.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 04:09:45 pm
content: Quote from: Simon on May 30, 2019, 03:32:31 pmI am not bothered with EMC.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 04:13:55 pm
content: Quote from: Siwastaja on May 30, 2019, 03:46:42 pmThen why do manufacturers says to use lower value ceramic and also higher value tantalum together for bypassing??

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 04:16:04 pm
content: Quote from: Simon on May 30, 2019, 03:32:31 pmI am going to use X5R.

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 04:45:01 pm
content: Quote from: Arjunan M R on May 30, 2019, 04:13:55 pmLow ESR is good but too much capacitance with a low ESR can cause instability. For reasons of cost and stability usually you use a large high ESR capacitor with some ceramic. The ceramic acts fast and by the time it is depleted the electrolytic is supplying power. It's about the frequency response. A fast edge has a high frequency component although the actual main waveform frequency may be low. It's that fast edge that the ceramic deals with.I have looked at a SMPS controller chip and it specifies that the output capacitor of 100µF must NOT be low ESR as the capacitor reacts so fast that it will make the control loop go unstable. But for good performance it wants low ESR capacitors on the input of only 2x2.2µF. You can pay £0.60 for a 100µF capacitor with 200mOhm ESR, a 28mOhm ESR capacitor is larger and costs £2.60.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 04:50:35 pm
content: I am using a 100nF ceramic and 10uF tantalum for bypassing ADC , DAC and VRef.Is that enough?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 30, 2019, 04:52:49 pm
content: So the manufacturers says to use 10uF tantalum for frequency response and stability.

author: Simon
author_rank: Unknown
timestamp: May 30, 2019, 04:59:45 pm
content: Quote from: Arjunan M R on May 30, 2019, 04:50:35 pmDo you mean you have one 100nF ceramic and one 10uF tantalum for all 3 or that they have a pair each?

author: Siwastaja
author_rank: Super Contributor
timestamp: May 30, 2019, 07:04:31 pm
content: Quote from: Arjunan M R on May 30, 2019, 04:13:55 pmHigher value tantalum has more inductance due to larger package, which, together with high ESR, prevents it from reacting to high-frequency noise.In parallel, they filter different frequency ranges.I comment about the inductance and package, because to be really effective, the small 100n cap has to be in the right place.When paralleling low-ESR capacitors of different size, there is a risk they form oscillating resonance frequency ranges, together with stray inductances. But when the larger capacitor has some ESR, it dampens this effect, like a shock absorber does with mechanical springs. Hence it's very common to see a combination of a small, low-ESR capacitance, combined with a much larger capacitance, but with considerable ESR. Tantalum is a very effective type for providing well controlled ESR. Of course, a MLCC + separate series resistor can be used as well.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:11:44 am
content: Quote from: Simon on May 30, 2019, 04:59:45 pmA pair of 100n and 10uF for 3 of those.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 04:46:45 am
content: which capacitor i need to use in here?electrolytic, tantalum or MLCC ?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 06:34:59 am
content: Quote from: Arjunan M R on May 31, 2019, 04:46:45 ami will use tantalum.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 06:44:26 am
content: Is adding a TVS diode to the input and output a good idea?

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 06:54:31 am
content: Quote from: Arjunan M R on May 31, 2019, 06:44:26 amInput of what?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 06:55:37 am
content: Quote from: Simon on May 31, 2019, 06:54:31 aminput of psu

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 06:56:27 am
content: Quote from: Arjunan M R on May 31, 2019, 04:46:45 amNo idea, consult the datasheets of the parts in question. 10µF looks quite big there.

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 06:57:56 am
content: Quote from: Arjunan M R on May 31, 2019, 06:55:37 amIf you are powering it off a mains transformer it should not be neccessary. No harm in using one if you want to. Be sure to understand all the specs of the TVS, they don't trigger on/off at a single threshold.

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 06:59:23 am
content: Quote from: Arjunan M R on May 31, 2019, 02:11:44 amNo, you want at least one 100nF per chip as close to the pins as possible, if the chips are all close you may get away with a single 10µF capacitor.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 06:59:47 am
content: Quote from: Simon on May 31, 2019, 06:57:56 amI am using a AC to DC adapter 19 V 2 A

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 07:03:28 am
content: Quote from: Simon on May 31, 2019, 06:59:23 amYes, I am using 100nF for every chips.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 07:41:56 am
content: Here is theTVS diodeI am going to use. I have read the full datasheet.It has a breakdown voltage of 22.2 to 24.5V. Max. reverse leakage current of 1µA. Max. clamping voltage of 32.4V. And maximum peak pulse surge current of 12.3A.That will be good enough for my purpose.

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 12:41:53 pm
content: Quote from: Arjunan M R on May 31, 2019, 07:41:56 amNo it won't, check the reverse standoff voltage. it will turn on at 22.2-24.5V but will not turn off again until 2-3 volts lower, if this is near the peak voltage of the supply you can get it triggered permanently.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 12:48:34 pm
content: Quote from: Simon on May 31, 2019, 12:41:53 pmits 20V(standoff voltage)

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 12:58:22 pm
content: there is no tvs diode with low standoff voltage with min breakdown voltage more than 20V in RS components. I might abandone the idea of tvs diode.

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 01:27:05 pm
content: Really? usually the reverse standoff in a few volts less than the breakdown voltage.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 01:33:33 pm
content: Quote from: Simon on May 31, 2019, 01:27:05 pmI mean that the value in the datasheet says 20V.

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 01:35:54 pm
content: where? remember hat one datasheet will over many parts

author: Simon
author_rank: Unknown
timestamp: May 31, 2019, 01:42:06 pm
content: https://uk.rs-online.com/web/c/semiconductors/discrete-semiconductors/tvs-diodes/?redirect-relevancy-data=636F3D3126696E3D4931384E53656172636847656E65726963266C753D656E266D6D3D6D61746368616C6C7061727469616C26706D3D5E2E2A2426706F3D31333326736E3D592673723D52656469726563742673743D43415443485F414C4C5F44454641554C542673633D592677633D4E4F4E45267573743D7476732064696F6465267374613D7476732064696F646526&r=f&searchHistory=%257B%2522enabled%2522%253Atrue%257D&applied-dimensions=4294702910

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 01:43:17 pm
content: wait i forgot the part number

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 01:44:44 pm
content: Quote from: Simon on May 31, 2019, 01:42:06 pmhttps://in.rsdelivers.com/category/tvs-diodes/9849#PI-1|PS-20|viewtype-0

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 01:58:17 pm
content: I think it will turn off at 20.5VIs that ok?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:01:57 pm
content: I will choose one with higher standoff voltage.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:04:22 pm
content: Quote from: Simon on May 31, 2019, 01:27:05 pmI thought that the reverse standoff voltage is the difference between when the TVS turns on and turns of.There is diodes with higher standoff in rs componentsQuote from: Simon on May 31, 2019, 01:42:06 pm

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:13:57 pm
content: I chosethis one.It has a maximum reverse standoff voltage of 24V. Minimum breakdown voltage of 26.5V and maximum clamping voltage of 70V.This will be okay.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:24:04 pm
content: Quote from: Arjunan M R on May 31, 2019, 02:13:57 pmIts differential resistance is too high

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 02:58:51 pm
content: Ok, final decision.I am going to use this TVS diode sm15t30cahttps://in.rsdelivers.com/product/stmicroelectronics/sm15t30ca/stmicroelectronics-sm15t30ca-bi-directional-tvs/4861253Diode ConfigurationSingleMaximum Operating Temperature+150 °CNumber of Elements per Chip1Length7.15mmMaximum Clamping Voltage53.5VMinimum Breakdown Voltage28.5VBrandSTMicroelectronicsMaximum Peak Pulse Current187APackage TypeSMCMounting TypeSurface MountMinimum Operating Temperature-55 °CWidth6.25mmTest Current1mAMaximum Reverse Stand-off Voltage25.6VMaximum Reverse Leakage Current1µAHeight2.45mmPin Count2Dimensions7.15 x 6.25 x 2.45mmDirection TypeBi-DirectionalPeak Pulse Power Dissipation1500W

author: Arjunan M R
author_rank: Regular Contributor
timestamp: May 31, 2019, 03:28:49 pm
content: Here is the datasheet of sm15t30cahttps://documents.rs-online.com/techlib://itc_doclist_GB.htm?stockno=4861253

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 01, 2019, 06:04:47 am
content: Can I use 6.3V tantalum capacitor to bypass 5V supply?

author: Simon
author_rank: Unknown
timestamp: June 01, 2019, 08:03:20 am
content: Just google tantalum capacitors, there will be lots of information. I don't know as i don't use them.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 01, 2019, 08:12:50 am
content: This is what it says on "Voltage Derating Rules for Solid Tantalum and Niobium Capacitors" by AVX.

author: Simon
author_rank: Unknown
timestamp: June 01, 2019, 01:33:08 pm
content: You can probably run closer to maximum with a stable voltage, if you are smoothing a fluctuating voltage you may want more headroom for surges/spikes.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 05:10:29 am
content: Hi, the LDO i am using (LT3080) needs a minimum output curent of 1mA.I was going to use lm334z as a constant current source.But it is only available in higher quantities.Can i use a electronic potentiometer as a constant current source?Or is there any simple circuits i can use as constant current source?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 05:12:59 am
content: Can you suggest a low cost feature i can add to my PSU?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 05:29:20 am
content: Look at this , I was looking for a switch.3D image in a pdf format.

author: Simon
author_rank: Unknown
timestamp: June 02, 2019, 08:01:17 am
content: what's your minimum voltage going to be?

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 08:05:46 am
content: Quote from: Simon on June 02, 2019, 08:01:17 amLt3080 can go down to near zero.I need my minimum voltage to be one or less than one.

author: Simon
author_rank: Unknown
timestamp: June 02, 2019, 09:09:50 am
content: a crude solution could be a resistor. To stop the resistor drawing a lot of power at higher voltages you can use comparators that switch in and out different resistors.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 09:57:59 am
content: Quote from: Simon on June 02, 2019, 09:09:50 amThe problem with resistors are that i will get false readings in m current measurement.If it is a constant current source or circuit i can just subtract the current of the constant current source.

author: Simon
author_rank: Unknown
timestamp: June 02, 2019, 10:04:10 am
content: Well you are shoehorning one thing on top of another. If this was designed properly it would not be a problem. The current sense could come after all of the regulation with the feedback being taken from the final output.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 10:09:07 am
content: Okay, i will not worry about the current measurement.Is there any way to constantly sink 1mA to a opamp?

author: Simon
author_rank: Unknown
timestamp: June 02, 2019, 10:14:09 am
content: There probably is but i can't be bothered right now.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 10:16:20 am
content: Quote from: Simon on June 02, 2019, 10:14:09 amI will try to make it myself.

author: Simon
author_rank: Unknown
timestamp: June 02, 2019, 10:19:41 am
content: that would be a good idea. Something along the lines of driving a BJT powering a resistor from the output while sensing the voltage across the resistor to keep the voltage constant.

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 11:23:40 am
content: MADE IT!!!!What it does is subtract 100mV(1mA x 100Ω = 100mV) from the output voltage of the regulator.And feeds it into the other side of the resistor.So that the current flowing through the resistor is always 1mA.The opamp used in the real circuit will be lm358.In the simulation it can work below even 500mV.I will build it using lm358 and test it out, i think it will work in lower than 1V.Here is the circuit (image)↓↓↓↓

author: Arjunan M R
author_rank: Regular Contributor
timestamp: June 02, 2019, 11:25:40 am
content: Here is the simulation in LTspiceEdit:Added buffered input to the differential amplifier and added the voltage divider.