• AVR Freaks

AnsweredHot!Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channels ?

Author
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
2019/07/12 10:32:28 (permalink)
0

Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channels ?

A simple solution for protection of PIC MCU A/D module with amplifiers with higher voltage supply then the PIC is zener diode and anti aliasing filters as simulated in the picture. 
 
I have two questions about the circuit;
1) How can we calculate the the R and C values of antialiasing filter for e.g 3k samples/per second ?
 
2) Is the reponse time of zener diodes sufficient to protect PIC 18F46K80 or PIC16F877a (circuit have almost 0.5 milisec)? Should we use protection circuits with op amps (OPA 698) to optain sufficient response time?
 
 

post edited by irmak - 2019/07/15 23:27:53

Attached Image(s)

#1
coffee critic
Super Member
  • Total Posts : 368
  • Reward points : 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/17 10:06:29 (permalink)
+1 (1)
This won't work.  The internal ESD diodes will fire well before the 5.1V zener diodes specified. 

n_*$
#2
PStechPaul
Super Member
  • Total Posts : 2342
  • Reward points : 0
  • Joined: 2006/06/27 16:11:32
  • Location: Cockeysville, MD, USA
  • Status: online
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/17 18:28:17 (permalink) ☄ Helpfulby irmak 2019/07/18 12:18:58
+1 (1)
Actually, the zeners will conduct in the forward direction, so they will never go into their reverse breakdown region, as long as there is an appropriately stiff Vdd supply. A better protection means might be Schottky diodes, although they tend to have significant leakage and capacitance. A TVS diode from the ADC input to GND might be better, although leakage and capacitance needs to be considered. Putting one across Vdd-Vss will help with protection if the input diodes conduct and the supply can't absorb the overvoltage.

 
#3
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 01:13:34 (permalink)
0
Many thanks for your detailed answer.
 
I have checked proteus for apropriate spice models but non of TVS have spice models and schottky diodes have suitable voltage in the VSM library.
 
q1) Do you have suggestions for TVS (5V; unipolar ?) and schottky (5V 1A ?) diode ?
 
TVS: https://www.mouser.com/pdfdocs/Semtech_Application_Note_TVS_Diode.pdf
 
SCHOTTKY:  www.farnell.com/datasheets/312532.pdf
 
q2) I am asking to make sure if I understand you correctly; I just  replace zeners with tvs or schottky in the simulated circuit and add an additional tvs or schottky between Vdd and Vss. Is this right ?
 
q3) For example how can I calculate r and c values for pic 16f877a to optain an apropriate anti aliasing filter ?
 
 
post edited by irmak - 2019/07/21 06:44:44
#4
ric
Super Member
  • Total Posts : 23185
  • Reward points : 0
  • Joined: 2003/11/07 12:41:26
  • Location: Australia, Melbourne
  • Status: online
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 02:28:53 (permalink)
0 (2)
irmak
and schottky (5V 1A) diode ?

You are misunderstanding what the schottky diode is doing.
Only the forward voltage drop is relevant, which will be more like 0.3V
 
Why 1 amp?
You would need one thousand volts before the 1k resistor to get an amp through the diode, in which case the resistor would disappear in a puff of smoke long before the diode expired! ;)
 
post edited by ric - 2019/07/18 02:31:12

I also post at: PicForum
Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
NEW USERS: Posting images, links and code - workaround for restrictions.
To get a useful answer, always state which PIC you are using!
#5
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 04:14:45 (permalink)
0
Dear RIC 
 
I think you have missunderstood my questions.
 
post edited by irmak - 2019/07/18 04:17:06
#6
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 04:23:56 (permalink)
0
I think I have found the suggested circuit with BAT54 (30V, 200ma) schottky diode and optional zenner.

https://www.analog.com/media/en/technical-documentation/tech-articles/Final-Protecting-ADC-Inputs.pdf
 
post edited by irmak - 2019/07/18 04:28:54
#7
ric
Super Member
  • Total Posts : 23185
  • Reward points : 0
  • Joined: 2003/11/07 12:41:26
  • Location: Australia, Melbourne
  • Status: online
Flagged as Spam (1)
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 04:36:47 (permalink)
+1 (3)
irmak
Dear RIC 
 
I think you have missunderstood my questions.

I think YOU have misunderstood what the diodes do.
 

I also post at: PicForum
Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
NEW USERS: Posting images, links and code - workaround for restrictions.
To get a useful answer, always state which PIC you are using!
#8
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 04:56:22 (permalink)
0
I think I have finaly suceed to find anti-aliasing filter calculation fomula
 
"To select a suitable RC filter, we must calculate the RC bandwidth for single-channel or multiplexed applications, then select values for R and C."
 
https://www.analog.com/media/en/analog-dialogue/volume-46/number-4/articles/front-end-amp-and-rc-filter-design.pdf
#9
PStechPaul
Super Member
  • Total Posts : 2342
  • Reward points : 0
  • Joined: 2006/06/27 16:11:32
  • Location: Cockeysville, MD, USA
  • Status: online
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 12:10:02 (permalink) ☼ Best Answerby irmak 2019/07/18 12:19:06
+1 (1)
TVS (and zener) diodes have a fairly soft "knee", as well as usually a 5% tolerance, so a 5.1V device may start drawing significant current at, say 4.8V, and may allow as much as 5.5V at rated current.
 
The PIV rating of the Schottky diodes is irrelevant, so any of the common 20-30-40 volt devices will be fine.
 
You probably don't want to make an anti-aliasing filter using the R-C network at the PIC ADC input, as its frequency response is "soft" and will affect accuracy. Generally the R-C values can be chosen based on the sampling rate such that its response will affect the accuracy less than about 1%. So if you want to measure a 60 Hz sine wave, at 1000 samples per second, the R-C time constant might be about 1 mSec, which will give less than 1% error at the fundamental frequency. Thus with a 1k series resistor, the capacitor would be 1 uF. However, if you want to observe harmonic content, you might want something like 100 nF.

 
#10
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 12:27:25 (permalink)
+1 (1)
Dear P Stech Paul
 
With your final response I have clearly understand design principles.
 
ADC protection circuits based on Schottky diodes are best solition and anti aliasing filters are not suggested due to their effect on A/D module if highest signal frequency is <sampling rate /2.
 

post edited by irmak - 2019/07/19 05:15:10

Attached Image(s)

#11
NKurzman
A Guy on the Net
  • Total Posts : 17599
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: offline
Flagged as Spam (1)
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/18 16:26:37 (permalink)
0 (2)
ric
irmak
Dear RIC 
 
I think you have missunderstood my questions.

I think YOU have misunderstood what the diodes do.




I think you misunderstand what SPAM is.
#12
crosland
Super Member
  • Total Posts : 1586
  • Reward points : 0
  • Joined: 2005/05/10 10:55:05
  • Location: Bucks, UK
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/19 03:01:49 (permalink)
0 (2)
irmak
anti aliasing filters are not suggested due to their effect on A/D module.

You misunderstood what was written. Anti-aliasing filters are almost always required, It's the use of an RC filter that is not recommended.
#13
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/19 03:37:12 (permalink)
0
Dear Crosland
 
crosland
irmak
anti aliasing filters are not suggested due to their effect on A/D module.

You misunderstood what was written. Anti-aliasing filters are almost always required, It's the use of an RC filter that is not recommended.




 
Then what is the role of r-c filter in the shematics?
 
Please read the pdfs in the links
==============================================================
 
The people who knows what they don't know ask questions,
 
The people who have experience writes significant answers 
 
but I am not sure what the people are doing  who dont know what they do not know :)))
post edited by irmak - 2019/07/19 05:25:45
#14
oliverb
Super Member
  • Total Posts : 204
  • Reward points : 0
  • Joined: 2009/02/16 13:12:38
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/19 04:25:27 (permalink) ☄ Helpfulby irmak 2019/07/19 05:02:22
+1 (1)
Regarding antialiasing filters it may come down to whether high-frequency signals are expected to be present. If the signal is expected to stay below 1/2 the sample rate then antialiasing may not be needed.
 
I seem to recall there were some issues with connecting a capacitor at an ADC input, as the input current of the ADC varied. This meant that either the RC time constant had to be short enough that the voltage would settle before the ADC made a comparison, or the C had to be large enough that the input current change would have negligible effect.
 
Regarding protection circuits there is an important distinction to be made:
1 Circuit protection to prevent damage to the device
2 Circuit protection to prevent incorrect operation of the device
 
Preventing damage may simply require that fault currents are kept below the clamping ability of the PIC's internal diodes, though the issue of the supply being driven to overvoltage potentially still exists
 
Preventing incorrect operation may be harder as it is nessecery to prevent the PIC internal diodes from conducting. As I understand it diode conduction leaks charge into the PIC substrate where it can then be collected by the ADC, causing massive measurement errors. I've observed that on a 4520 a negative input disrupted all analogue readings, though the program continued to run.
 
 
#15
irmak
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/07/05 23:50:12
  • Location: 0
  • Status: offline
Re: Is Simple H-Voltage Protection Circuit Response Time Sufficient to Protect A/D Channel 2019/07/19 05:09:56 (permalink)
0
Dear Oliverb
 
Many thanks. I have updated final decision according to your explanations.
 
 
I use oversampling and downsampling in matlab for antialiasing related problems.
 
Do you suggest a downsampling method for PICS without A2D ?
post edited by irmak - 2019/07/19 05:16:35
#16
Jump to:
© 2019 APG vNext Commercial Version 4.5