Vary voltage and frequency of Square Wave

AI Thread Summary
The discussion focuses on generating a variable voltage square wave using an AtMega32 microcontroller. The user is successfully varying the frequency with Timer1 but seeks advice on adjusting the voltage level of the output. Suggestions include using a four-quadrant multiplier or a variable gain amplifier to control the amplitude based on a control voltage. The conversation also mentions the potential of using a multiplying R2R DAC for programmable gain control and suggests exploring CMOS technology for precise voltage switching. Overall, the thread provides various circuit ideas and components to achieve the desired voltage modulation.
Etude
Messages
28
Reaction score
0
Hi!

I am using an AtMega32 to output a square wave. I am varying the frequency by toggling the output pin using Timer1.
However, I also need to vary the voltage of the wave and frankly, have no idea how to. I tried looking up google but not much of it made sense to me thanks to my limited knowledge of electronics.
Can anyone please help ? I don't have to use the micro controller so even circuit ideas are open. Can I use some kind of voltage controller to modify the wave after the square wave of the set frequency has been output from the micro controller port?
 
Engineering news on Phys.org
Look into a 4 quadrants multipliers. I used this one before:

http://www.analog-innovations.com/SED/MC1594-DataSheet.pdf

But this one is more for RF, it is just an example what you need to look for. I don't know your requirements, whether it needs to be precision, DC couple or anything. I use this a long time ago. Also the down side is when you have highest attenuation, the noise goes way up, so there is a limit of how low the gain can go.

There might be some newer ones you can use to fit your needs. Basically, it take your square wave input and change the amplitude according to a control voltage. With a 4 quad multi, you just feed from the source you have and control the amplitude with a control voltage.

Also look into variable gain amplifier something like this:

http://www.ti.com/lit/ds/symlink/lmp8358.pdf

I am not recommending these two device, just an example to give you a head start what direction to look for. Most likely they have better ones for your specific needs.

If you can take AC couple, and the frequency is in over 1MHz, then I had a design that use pin diodes that will do the trick.
 
Last edited:
Hey thnx a lot! will try understanding these :)
 
It sounds like a good place for CMOS. CMOS is analog designers dream, because it can switch right to a given voltage.

I'd suggest looking through the CD4051-CD4053 analog switches. They're cheap as dirt and twice as common. You can place your positive voltage on one input and negative on another and have a lovely square wave that's very well defined.
 
Hi all I have some confusion about piezoelectrical sensors combination. If i have three acoustic piezoelectrical sensors (with same receive sensitivity in dB ref V/1uPa) placed at specific distance, these sensors receive acoustic signal from a sound source placed at far field distance (Plane Wave) and from broadside. I receive output of these sensors through individual preamplifiers, add them through hardware like summer circuit adder or in software after digitization and in this way got an...
I have recently moved into a new (rather ancient) house and had a few trips of my Residual Current breaker. I dug out my old Socket tester which tell me the three pins are correct. But then the Red warning light tells me my socket(s) fail the loop test. I never had this before but my last house had an overhead supply with no Earth from the company. The tester said "get this checked" and the man said the (high but not ridiculous) earth resistance was acceptable. I stuck a new copper earth...
I am not an electrical engineering student, but a lowly apprentice electrician. I learn both on the job and also take classes for my apprenticeship. I recently wired my first transformer and I understand that the neutral and ground are bonded together in the transformer or in the service. What I don't understand is, if the neutral is a current carrying conductor, which is then bonded to the ground conductor, why does current only flow back to its source and not on the ground path...
Back
Top