The Xilinx Spartan3e starter kit
here
is a great board for playing around with some of the projects on this website. However, one serious drawback with it is the
single bit RGB output on the VGA connector. This only allows 8 colours (including Black) to be displayed.
I wanted 4 bit RGB which would give me 16 shades each of Red, Green and Blue - or a total of 2 to the power 12 colours (4096). Below is the output of
the test application, and you can download the source code and binary for it at the bottom of this page.
It produces a 800x600 72.19 Hz test pattern.
The top half shows all 16 levels for each channel, and the bottom tests each bit in turn, so you should see 4 colour bars for each primary
which tests each resistor in turn. (Highest resistor value at the left corresponds to the darkest level, down to the lowest value at the right which gives the brightest,
then repeat for next colour).

The modifications are simple, but there is a risk of damaging the board if you get it wrong, so please only attempt this if
you understand the instructions and are confident to do so.
The board has a single 270 Ohm resistor between an IO pin and the Red (for example) output. This gives a voltage of approximately
0.7V on the VGA pin when terminated by a standard 75 Ohm load.
We need to change this resistor value, and add three more resistors between
each VGA colour output and an FPGA IO pin. We need these four resistors to keep doubling in value and the parallel combination
needs to be around 270 Ohms still to give a 0.7V peek output. From the E24 serious 510 Ohms, 1K0 Ohms, 2K0 Ohms and 3K9 Ohms will do nicely.
You could also use 510,1K, 2K2, 4K7 if you wished.

First, change the three 0402 270 Ohm resistors just below the VGA connector (you can see the traces going to pins 1,2 & 3) to be 510 Ohms.
This is the MSB of our output, and has the advantage that applications that use the standard pins will still get a reasonably bright picture.
These are the standard output pins on the fpga :
O_VIDEO_R(3) FPGA PIN = "H14" (510 Ohm Resistor)
O_VIDEO_G(3) FPGA PIN = "H15" (510 Ohm Resistor)
O_VIDEO_B(3) FPGA PIN = "G15" (510 Ohm Resistor)
The easiest way to add the other resistors is to solder them on the back of the board onto the pins of the FX connector (J3). The other
end of the three resistors are tied together and wired to the correct pin on the VGA connector (pin 1 - Red, pin 2 - Green, pin 3 - Blue)

O_VIDEO_B(2) FPGA PIN = "B4" FX2_IO1 FX2 pin 6 (1K0 Ohm Resistor)
O_VIDEO_B(1) FPGA PIN = "D5" FX2_IO3 FX2 pin 8 (2K0 Ohm Resistor)
O_VIDEO_B(0) FPGA PIN = "A6" FX2_IO5 FX2 pin 10 (3K9 Ohm Resistor)
O_VIDEO_G(2) FPGA PIN = "A13" FX2_IO21 FX2 pin 26 (1K0 Ohm Resistor)
O_VIDEO_G(1) FPGA PIN = "A14" FX2_IO23 FX2 pin 28 (2K0 Ohm Resistor)
O_VIDEO_G(0) FPGA PIN = "C14" FX2_IO25 FX2 pin 30 (3K9 Ohm Resistor)
O_VIDEO_R(2) FPGA PIN = "A16" FX2_IO27 FX2 pin 32 (1K0 Ohm Resistor)
O_VIDEO_R(1) FPGA PIN = "E13" FX2_IO29 FX2 pin 34 (2K0 Ohm Resistor)
O_VIDEO_R(0) FPGA PIN = "B11" FX2_IO31 FX2 pin 36 (3K9 Ohm Resistor)
This is what my board looked like after the modification :
  
THIS CODE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
You are responsible for any legal issues arising from your use of this code.
You must agree to this disclaimer before downloading the code
Version 001 Initial release display_test_rel001.zip
|
|