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.

Square wave signal with ADC converter

Status
Not open for further replies.

tnnedaboard

Member level 3
Joined
Apr 5, 2012
Messages
64
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,748
Hi,
I have a 7Hz 5Vpp square wave signal, you give me an advice on an easy way, to turn that signal into the corresponding DC voltage, so I can read it through the microprocessor's ADC converter?

Thank you.
 

Hi,

to turn that signal into the corresponding DC voltage
define "corresponding"
* frequency
* amplitude
* duty cycle
* or something else?

Klaus
 

the request is:
take a square wave signal with a fixed width of 0-5V and a variable frequency (3Hz to 10Hz, approximately) and convert it into a continuous signal ...
I hope I was clear...
 

the request is:
take a square wave signal with a fixed width of 0-5V and a variable frequency (3Hz to 10Hz, approximately) and convert it into a continuous signal ...
I hope I was clear...

Uh, a real world square wave is a continuous signal. It certainly isn't a theoretical signal with an infinite transition slew rate producing a signal with only two states.

The sampling rate of this square wave is going to be directly related to the slew rate of the transitions as that defines the highest significant frequency component of the square wave. Suppose if your transitions are 1ps then you'll need to sample your square wave at 2 GHz (doubtful your uP ADC can do that). If you square wave has a nice slow rise time (as it probably should given it's only 3-10Hz) then you probably have uS of rise time which means you can easily capture your square wave with MHz of sampling rate.
 

Hi,

Do you mean something like a precision rectifier before the ADC? What is the continuous signal derived from - on time and off time of a DC signal or is it something that swings below ground to -2.5V and above to +2.5V?

- - - Updated - - -

Or is the goal to only measure the positive going peaks and hold them with a sample and hold circuit before the ADC until the next peak?
 

It's not clear if you want to read the level of a variable frequency (about 3-10 Hz) square wave signal or something else. What about the accuracy you need ?
Why you have to convert the signal into "corresponding DC". Can't you just feed the ADC with your signal (after level shifting, if needed) then process it via software ?
 

FYI the OP has stated the signal is 0V to 5V so it looks like a slow digital 5V CMOS clock signal.

I think what they are trying to do is measure the frequency.

Not sure how you measure time in a micro, but if you can measure time just sample the clock with the ADC and find the transitions of the signal for both high/low and low/high (average if you want better accuracy) then you can get the frequency by 1/(2x).
 

Well.... if it isn't the frequency they want, than answer is 2.5V ! (and I didn't cheat and use an ADC)

Brian.
 

Hi,

the request is:
take a square wave signal with a fixed width of 0-5V and a variable frequency (3Hz to 10Hz, approximately) and convert it into a continuous signal ...
I hope I was clear...
From the posts .. you schould recognize: it´s not clear.

If you want duty cycle: (and the LOW and HIGH levels are clean) then a low pass filter does the job
If you want freuqwncy: then a F-V converter does the job
and so on. ...
We don´t know what you need.

Klaus
 

I agree that the question isn't completely clear, but it seems more likely to me that the OP wants to measure the square wave magnitude rather than its frequency.

Depending on the intended accuracy, linearity and response time, you can use an active or passive rectifier circuit, or possibly a peak detector.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top