Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Help me with sampling ac voltage using ADC0820

Status
Not open for further replies.

gsnik

Newbie level 4
Joined
Sep 18, 2005
Messages
7
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,364
sampling ac voltage

i want to sample ac voltage at 50 hz using adc0820 along with 8051 and display the rms value. what should be the sampling frequency ? where should i store the samples ? how to calculate rms from samples ? i am a total novice please help me out
 

Re: sampling ac voltage

As much as you can, more samples more acurate measurement.
Urms = SQR((Us1*Us1 + Us2*Us2 + ....Usn*Usn)/n)

Greetings
Dragan
 

Re: sampling ac voltage

How accurate do you need to be? Is the waveform a pure sine wave without harmonics?

If the answer to the above is a few percent on a pure sine wave, you can use a peak detector op amp circuit and multiply the DC voltage out by the square root of two. Another method is to find the peak by taking many samples and forming a peak detector by comparing each sample with one stored in a register. If it is higher, put the new value in the register.
 

Re: sampling ac voltage

If your signal is a pure siunsodial one at least you need 100Hz sampling rate according to theories. I think it is better to have a sampling rate of 200 samples / sec
will give a better performance.

Best Regards
Randika K
 

sampling ac voltage

Since your frequency is known, I suggest that you use a four samples, of course if you have a pure sine wave without harmonics. This mean that your sampling frequency is 200Hz, than you can use the next formula:

U= 1/4 * sqrt{ (U1+U2-U3-U4)^2+(U1-U2-U3+U4)^2 }

with this method you will filtreate an unilateral signal . I used this method with ATmega48 and it was works fine.
I hope you understand me, since my english isn't good
 

Re: sampling ac voltage

If voltage contains some harmonics,how can we sample this voltage?
 

Re: sampling ac voltage

gsnik:

Translate thiis:
---------------------------------------------------------------------------------
Como eres novicio segun tu decir, te darè una opinion practica,
La frecuencia que quieres leer es de 50 Hz,si quisieras mostrarlo en un grafico
y que la onda sinusoidal sea facilmente visible ,seria necesario al menos
digamos 20 puntos (pocos) entonces ,mejor elegir mas puntos de modo que tambien se vean las imperfeccciones o armonicos o los ruidos espureos.
digamos entonces 1024 puntos .De esta manera 50*1024=51200 hrz
(veces por segundo)
Por otro lado,veo dificil que el microprocesador pueda procezar tanto en tan poco tiempo salvo que sea muy rapido,por ejemplo ,con 100 instrucciones por dato recibido,seria necesario aproximadamente 20MHZ o mas.
Espero te oriente.
--------------------------------------------------------------------------------------
 

sampling ac voltage

one of simplest way (but not accurate)is:
sample AC voltage with one (for example) 220/3 volt transformer. then rectify and smooth it. with this approach you get DC voltage which is equal to VDC = (1/transformer turn ratio) * 1.4 * (RMS AC input)
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top