01-30-2012 06:30 PM
Hi I am currently trying to sample a sine wave from a function generator using the ADC on the Spartan 3A and then output the data via the DAC to an oscilloscope. I have so far de-bugged my pre-amp and DAC settings and therefore am fairly confident that the problem is with my ADC settings.
Essentially the problem is that the data streaming from the ADC to the FPGA is amplified by a factor of around 2.6. This data I can effectively output onto the scope from the DAC.
I have set up a simulation that takes into account all the parallel to series and series to parallel conversion that the SPI would make and I have lined up the FPGA input clock edges from my simulation ADC to take in data when it is stable according to the user guide. I have taken into account the 2's complement issues by inverting the MSB out of the ADC before sending the data to the DAC and therefore offsetting the data into the desired range for the DAC.
I have attached picture of the simulation of just the ADC shift register at work and I think as it is it looks exactly as the user guide says it does. PLEASE correct me if I'm wrong.
I am basically now running out of ideas and am desperate for some guidance. I have looked on the forums and it seems like noone else really has had a problem like this. Any suggestions would be appreciated.
01-30-2012 07:05 PM
You probably mean the Spartan-3A Starter Kit, not the Spartan-3A itself (which doesn't have an ADC)
I'm not familiar with the parts on this board so your simulation doesn't mean anything to me, but here are some things to consider:
01-31-2012 12:36 PM
Hi thanks for your reply, I have sorted out my issues. I actually had misread the user guide!