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.
Try the "DDS Compiler" or "Direct Digital Synthesizer" cores included with Xilinx ISE CORE Generator.
Or build your own DDS. Feed a frequency constant into an ordinary arithmetic accumulator. Connect the accumulator output to the address inputs of a sinewave lookup table ROM. The ROM output is your digital sinewave.
okies i got my 8bit
but i don know what happen it only show me the wave half way . from 0000 to 0101001
the rest nothing ....
i don know why . any one
help~~ please
What software are you using to display the wave? If it defaults to unsigned value display, then you should configure it to display signed values (both positive and negative). In ModelSim, right-click the signal's name in the wave window, select Properties, and then explore the various options.
What is the name of the software that's showing you the incorrect waveform?
Can you show us a screen image of the malfunction you see?
Have you configured your waveform viewer to show signed (positive and negative) values?
In your VHDL testbench, where is your "DDS" component? If it's a core, which one did you use, and what parameters did you specify to create it?
Your testbench simulates fine in ModelSim 6.3c. I generated an 8-bit DDS core using Xilinx coregen and "DDS Compiler 2.0". The clock is 500 MHz, the sinewave is 120 MHz. Here's a screen image. The vertical scale on the "sine" signal is from -128 to +127:
err how to check whether the vertical scale on the "sine" signal is from -128 to +127 .
and is there a way you can shift the whole "sine" singal to upper the Zero like moving the whole sine above zero
Your 'sine' signal is displayed as simple binary, so it has no vertical scale. Earlier, when you said it was displaying only "half way", I thought you meant in the vertical direction, not in the horizontal direction. My comments about signed and unsigned therefore don't apply.
The Xilinx DDS core shouldn't run at all during the first 100ns, because the FPGA's global reset signal is active. Your signals are somehow active before that time, and then become undefined after a few clock cycles. Also, your signals appear to change on the *negative* edge of the clock instead of the positive edge. Very strange!
Your screen snapshot shows only the first 35ns. Does anything interesting happen after 100ns?
To display the "sine" signal as an analog waveform (like my snapshot), right-click the signal name, click Properties, change the radix to decimal, change the format to analog, change the offset to 128, change the scale to 0.5, and change the height to 128.
I've never seen a malfunction like your display. I don't know what's wrong. Maybe it's an installation/configuration problem between ISE and ModelSim. Be sure you have installed all the available ISE and IP service packs. Which version of Xilinx ISE are you using?
Your screen snapshot looks like a pre-route simulation. Is that correct, or is it a post-route simulation? If it's a post-route simulation, then I don't think any Xilinx device can run the DDS core at 500 MHz, so maybe that's what's wrong. Does ModelSim give you any timing warning messages?
Maybe you could zip up all your project files and upload them somewhere, so someone could try to figure out what's going wrong.
err nothing after 100ns is all the red line
errr what you see. is all i have
don know why when i run 9 or 10 bit nothing wrong
you can go all the way to 100ns but . when i try on 8bit . error . anyone know how to solve
When I use your dds.vhd file, I now see the malfunction.
Your 'sclr' pulse is too short. It isn't providing good setup time before the clock. I lengthened the pulse, and the simulation now runs fine with your dds.vhd file. However, it is on the verge of failing due to high clock frequency. If I slightly increasing the clock frequency, I see the DDS output update rate drop in half - it is probably missing every other clock cycle.
Remember that 500 MHz is probably too fast for this DDS core in any Xilinx device.
You wrote the testbench that generates the sclr pulse, so you should know how to change it!
Here's your statement that sets the sclr pulse width:
sclr <= '1','0' after 1 ns;
The simulation malfunctions because sclr has bad setup time, not because the clock is too fast.
However, the simulation is just barely working at 500 MHz. It malfunctions at 501 MHz.
The core probably won't work in an FPGA at 500 MHz.
Try changing the sclr pulse width from 1ns to 3ns, so it is high both before and after the rising edge of the clock.
You can zoom in on the ModelSim wave display to see the relationship between clk and sclr.
If you simply wish to adjust the appearance of the wave in ModelSim, see my earlier message about setting the radix, format, offset, etc. That configures the wave's vertical offset and amplitude to appear like my ddswave.gif snapshot.
I have version 6.3d of ModelSim, so my menu arrangements and parameter names may be different from yours. ModelSim rearranged them around version 6.3.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.