Electronical and Electromechanical Explorations

This blog organizes and presents some of my various projects and musings related to taming wild electrons and putting them to work. Projects are listed down the right side of the page.

Wednesday, January 14, 2015

Signal Generator 1: High Level Design

One piece of test gear that I need is a reasonably-capable signal generator, for testing the response of circuits (in combination with an oscilloscope, usually).

It struck me that a project like this is a perfect excuse to get some experience with FPGAs, so I thought I'd start out by sketching out a high-level design that I can use for component selection and so on.  It seems like a rather straightforward task, although as always the devil is in the details -- and everything looks easy until the reality sets in!

My basic requirements are:
  • 2 channels of output
  • 200 MSPS output sample rate
  • +-/- 10 volt output range; reasonable fidelity down to 10-ish millivolts peak to peak
  • Enough output current to drive a 50-ohm transmission line (plus a bit more).  250 mA is probably enough, 500 would be nice
  • Basic set of signal types, including pulse trains, amplitude modulation, etc.  Details to be worked out later
 The basic plan is to use an FPGA to generate the signals in the digital domain, either on-the-fly or (if necessary) by filling a memory buffer... with a provision for accepting an arbitrary waveform buffer from an external microcontroller.  Then feed the digital signal to a DAC, which then goes through an amplification and buffering stage.  To maintain accuracy, there will be an ADC for measuring output signals during a self-calibration process (and possibly during normal operation).

Here is a block diagram showing all the parts (just one output channel shown for simplicity).  Below the diagram, each part is briefly explained:
  1. Power:  Regulators to provide all the power rails needed, from a +12v input
  2. LCD for nice UI
  3. Touchscreen to simplify setting complex parameters
  4. Buttons and knobs for functions that operate better from hard controls
  5. External communication (USB probably)
  6. Accurate low-jitter clock generator to synchronize the MCU/FPGA/DAC and drive conversion
  7. Microcontroller for UI, communication, and FPGA control
  8. FPGA: almost certainly I will use a Spartan 6, which is pretty powerful, inexpensive, and solder-friendly
  9. DAC: I picked up a couple cheap DAC5672 on ebay: dual 14-bit 275 MSPS in easy TQFP-48 package
  10. Current to voltage conversion
  11. Filter to exclude high frequencies (which come from "steps" in the conversion).  Still want square waves to be square, though, so it's a tradeoff.
  12. Amplification to output voltage range.  Ideally this would be externally programmable (shown here with an auxiliary DAC), from -20dB to +20dB.  The details need to be worked out.
  13. Gain control for the amplifier
  14. AC coupling to remove any offset artifacts
  15. High-current output buffer.  Also moves the signal to its target common-mode voltage.
  16. Common-mode output voltage control for the output buffer
  17. Signal buffer for feedback measurement pathway
  18. Fixed attenuator to move the signal down to a range the ADC can handle
  19. ADC for signal measurement during self-calibration
  20. Solid-state relay to shut off the output (under user control and also during self-calibration)
  21. Impedance control for output transmission line
  22. Output jack (BNC)
This looks pretty complicated, but I don't think it should really be that bad.  Each element is relatively straightforward (not counting the FPGA magic...)

I have a little Spartan 6 development board, so the next step will be the agonizing component-selection process, after which I will construct a prototype of the output stage (all the stuff shown in yellow and blue).

Also I will work more on specifying features so I can think more carefully about how to implement it in the FPGA.  Since I haven't ever used an FPGA in a project so far, it will be something of a learnign curve... but that is 68.2% of the fun!








No comments:

Post a Comment