Dave's Low Cost 10MHz DDS Function Generator with a PWM output - Page 1
Forum section: electronics / projects

author: Unknown
author_rank: Unknown
timestamp: December 21, 2009, 09:46:27 am
content: Hi all,since this is my first post I should introduce my self. I'm a student that wants to learn more about electronics and DSP.I have built Dave's Low Cost 10MHz DDS Function Generator and I must say that it helped me a lot in my process of learning. Next step is to integrate a PWM output in the circuit, so I wired another LM 6361 and a POT as I draw over the drawing of the circuit, but that is not working as I thought. If some one have any suggestion please be kind to point them out.Here is the original and a redraw circuit respectivelyThe change is the upper right cornerThanks in advanceRegards,Nenad Ilic

author: jahonen
author_rank: Super Contributor
timestamp: December 21, 2009, 07:59:15 pm
content: It doesn't work because LM6361 uses single-supply and you are feeding it with bipolar signals. Your input common-mode range is exceeded. Use dual-supply instead. Or add some AC-coupling and bias resistor to bias signal into common mode range. BTW, you should be better off by replacing the LM6361 with some high-speed comparator.Regards,Janne

author: Unknown
author_rank: Unknown
timestamp: December 21, 2009, 09:09:31 pm
content: Thank you for a quick replay. I was thinking of replacing LM6361 with a LM360?? Do you have any suggestions what other comparator I should use. I'm having a trouble finding a high speed comparator that can go up to 10 MHz.EDIT: What about using LT1016. It also has an inverted output that may come in handy.Thank youRegards,Nenad Ilic

author: jahonen
author_rank: Super Contributor
timestamp: December 22, 2009, 04:51:49 pm
content: LT1016 looks ok for the purpose. Other things what come into mind, why not take the input of the comparator from just before the output adjust potentiometer (just after C12) so that amplitude adjustment does not affect the duty cycle. If I understood the AD9835 datasheet correctly, the signal amplitude is around 1 Vpp at that point. Enough for the comparator, anyway.Also, limit the adjustment range so that you just achieve 0% and 100% duty cycles at the extremes of the duty cycle adjustment. That can be accomplished by adding two resistors, one between +V and duty cycle adjust potentiometer, and one between -V and potentiometer. Calculating the values of these resistors so that you get the proper adjustment range is a nice exercise for circuit analysis/synthesisThe output of the LT1016 certainly needs some care. The edge rate is very high. Too high edge rate will cause reflections and false triggering of edge sensitive devices if output, line and load are not impedance controlled/terminated. I suggest taming (slowing) it somewhat by putting appropriate capacitor (something like 10-100 pF perhaps, experiment with that) between output and ground, if not using series termination like Dave's original sine output, which is also recommendable.Also don't forget that you can simulate the operation with LTSpice easily since LT1016 is a linear technology part.Regards,Janne

author: Unknown
author_rank: Unknown
timestamp: December 26, 2009, 09:14:42 pm
content: Thank you for your help. I will do a simulation and post the result.Regards,Nenad Ilic

author: Unknown
author_rank: Unknown
timestamp: December 29, 2009, 12:48:17 pm
content: Quote from: nenadilic84 on December 21, 2009, 09:46:27 amAlthough you didn't ask for it, first thing I would do is to replace the display with a cheap surplus HD44780 compatible character display. You need, as a minimum, 6 pins to drive such a display, and you have more than that currently driving the LEDs and the 7-segment single digit display.

author: Unknown
author_rank: Unknown
timestamp: December 30, 2009, 09:56:29 am
content: Here is the circuit simulated. Everything works just fine, but the output voltage is pulsing between 0 and 3.6V. Is there any way to make it 0-5V pulses.Thanks.Regards,Nenad

author: Unknown
author_rank: Unknown
timestamp: December 30, 2009, 10:03:47 am
content: Quote from: Andrew on December 29, 2009, 12:48:17 pmThank you for your suggestion. I was thinking about that. Do you have an example code in C for communicating with HD44780.Regards,Nenad

author: jahonen
author_rank: Super Contributor
timestamp: December 30, 2009, 02:33:22 pm
content: Quote from: nenadilic84 on December 30, 2009, 09:56:29 amBuffering the output with 74HCT14 (or perhaps even 74ACT14) should do it.Regards,Janne

author: jahonen
author_rank: Super Contributor
timestamp: December 30, 2009, 03:04:20 pm
content: Quote from: nenadilic84 on December 30, 2009, 10:03:47 amI have some code for MSP430 family + HD44780 compatible controller. I can post it if it helps.Regards,Janne