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 to sine wave convertor ,

Status
Not open for further replies.

hm_fa_da

Full Member level 5
Joined
Sep 16, 2003
Messages
287
Helped
10
Reputation
20
Reaction score
4
Trophy points
1,298
Activity points
3,217
square to sine rc

hi all ,

i am making a 12KHz square wave using Microcontroller and want to convert it to sine wave ,
can u help me making a simple circuit doing this ?

and then i am going to modulate it on telephone line ,
can i put a transistor between line power series whith telephone and then connect the output of the sine wave to base of the transistor ?(does the sine wave remain sine or again changed to square ? how about if i connect a resistor between collector and base ?

Thanks ,
and best regards.
 

saw to sine convertor

Use a simple band pass filter. One op amp should to it.

The telephone system will not pass this out of voice band signal. It also may be illegal in your country to put out of band signals on the line.
 

square to sine low pass

A band pass filter will pass a whole band of sine waves, if you want a single frequency thne you have to use an OSCILLATOR (crystal or LC).
 

telephone line 0.47uf

you can use a bandpass filter or nonlinear device such as diode or bjt.
you can use an opamp and tow bjt to convert square to sin ,
the same method signal generators works
 
Thanks from all ,

Can you please give a schematic ?

and also i saw an application note describing how to make DTMF tones using PWM , it says it is possible to make sine waves using PWM ,
and you should change Duty cyle each time , then the Average voltage would be a sine wave .
i think this is a good way too ??

here is the pdf file of that application note :
 

Yes, a bandpass or lowpass filter works great. It can remove all the higher harmonics and gives you a clean sine wave. Search Google or your bookstore for filter design books.

This web page on telephone circuits may be helpful:
http://www.egyed.com/faq/phonework.html
 

Hi;
In the Centeral Office telephone systems 12KHz or 16KHz is
used for (analog) signaling with coin box telephone.
This signal used for getting coin in the coin box telephone.
The direction is from C.O.(Centeral Office Telephone System)
to telephone, not telephone to C.O.
because you can not pass signals above (3.4 ~ 4 KHz) to the telephone lines.
anyway you can use bandpass filter to produce sine wave from square wave.
and after amplification to desired amplitude, you can inject it to telephone line
with use of 0.1uF-0.47uF(bipolar eg. multilayer) capacitor.
it is beter to have balance signal and inject it in 2 line of telephone lines.

Regards
Davood Amerion
 

Another solution you could consider if the filter introduces too much phase shift (and if that is a problem), is to use a PLL approach. Synchornize a PLL with your digital clock.
 

If you are using 12KHz for pulse metering then you must switch it on and off. In order for the switching noise to be relatively inaudible use a second order bandpass filter. Do not use a very high Q filter because the timing of your 12KHz pulses will change. If you want to inject just a sinwave any second order low pass will do (Chebychev MFB filters are very good for your application). Texas Instruments has FilterPro a very good program for calculating filter components and it is for free. You can use almost any opamp you have since your frequency is low but especially if you design band pass use low tolerance capacitors. Since all telephony signals are differential (metallic is the term used in telephony) you can use a second opamp in inverting topology with gain of 1 to drive the second line. Use small value (around 47nF is O.K. to act as a high pass filter) and high voltage (must be at least 200V to withstand the ringing signal) capacitors to AC couple the ouput of your opamps to the line. Avoid driving the line directly from the output of the opamp through the coupling capacitors best use two 100R resistors in series. The termination of the 2-wire telephone line for 12Khz (and 16KHz) signals is 200R but you do not need to be at exactly that value. The small capacitance for AC coupling is essential to protect your opamp from the low frequency (20Hz, 25Hz or 50Hz depending on your country) high amplitude ringing signal. Consider using a protection scheme at the output of your opamp.
 

Thanks for all Helps ,

i have one free opamp in my circuit ( one of four opamps in LM324 ) , and a MCU making 12KHz signal .

what's better way : ?
make a RC low pass capacitor and then buffering it using opamp ( opamp = as line follower ) ,

or making an active low pass filter with that opamp ?( both filtering and amplifing )

this 12KHz signal should be turned ON and OFF i.e 200mls , 200mls ON = 1 , 200mls OFF = 0 , so can use this to send i.e 4 bit codes .

and also the one free opamp is in LM324 which other 3 opamps are used as speech active bandpass filter ,
does this make a higher noise on speaker than using a seprate opamp ???

Thanks and Best regards.
 

2 hm_fa_da

I suppose that you are wishing to pass signals from one telephone to another using 12 KHz modulation . If it is true - that wont be possible (if exchange is not quite old). But if you are doing coin telephone circuitity - that is another story.

Regarding filter - if you are going to make sinus by filtering square wave - better to make LP filter as you dont have lower than 12 KHz harmonics . May be it would bew better to pass signal through logarithmic circuit ( diode based ) before to reduce high harmonics to some extend.

But it is worth to use pwm - just only first order LP filter will be enough for you (dependent on PWM freq and allowable outof speech band noise).

Regarding your questions
"make a RC low pass capacitor and then buffering it using opamp ( opamp = as line follower ) ,
or making an active low pass filter with that opamp ?( both filtering and amplifing )"

Write down your requirements on out of speech band noise level (if you have such ), or state if you dont care - that wil define what filter order is to be designed (for powm and square to sin methods)

LP filter output buffering - we dont know input resistance of your output stage to telephone line connection, without that necessity in opamp based buffering can not be justified.
.. and quadro opamp crosstalk is not and issue within telehone due to reliable signal level you operate within you design.
 

because of low frequency of MCU ( 1MHz ) it's not possible to use PWM , only i can generate 12 square wave with 50% duct cycle . i am going to use this schematic for output of my MCU , i don't know how much should the R and C be .
please help me choose a good value for this low pass filter :

Thanks & best regards.
 

Choose RC using the following formula:
RC=1/2Πf
f=frequency of 50% square wave ..
For example, if frequency is 1MHz and R=1kΩ --> C≈160pF ..
Regards,
IanP
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top