1

我正在尝试通过 VGA 连接器为具有 Altera FPGA 的 VGA 显示器创建通用图形控制器,但我找不到任何好的在线资源来解释显示器使用的标准规范。我找到了所有的引脚描述和一些描述如何创建特定图形控制器的资源,例如这个8 色 480x640 控制器,但我没有找到任何资源描述实际预期的监视器“协议”。

例如,我在任何地方都没有找到信号不同部分之间的确切时序应该是什么——在上面,给出了以微秒为单位的具体时序,但没有给出原因。是否所有部分都应该按照这些设定的比例,或者在行之间的暂停时间方面是否存在一些任意性等等......如果您考虑在代码中实现它,伪代码会是什么样子(并且能够改变分辨率/颜色深度)?

同样,我正在寻找通用控制器的预期“协议”——类似于没有指定监视器类型时操作系统将使用的协议。指向正确方向的指针将不胜感激。

4

2 回答 2

3

多年来我没有做过任何较低级别的 VGA 东西,但我用过的一本书可能会有所帮助:EGA、VGA 和超级 VGA 卡的程序员指南

本书的目录如下:

  1. 程序员指南简介
  2. EGA、VGA 和 Super VGA 功能
  3. 图形硬件和软件
  4. 图形系统的类型
  5. 计算机图形学原理
  6. 字母数字处理
  7. 图形处理
  8. 调色板和颜色寄存器
  9. 读取 EGA 和 VGA 的状态
  10. EGA/VGA 寄存器
  11. EGA/VGA BIOS
  12. 编程示例
  13. 超级 VGA
  14. 图形协处理器
  15. 超级 VGA 代码基础
  16. 适配器接口
  17. 8514/A
  18. XGA
  19. ATI 技术
  20. 芯片与技术
  21. 卷云逻辑
  22. Video7 Super VGA 芯片组
  23. IIT
  24. NCR
  25. 橡木
  26. S3 公司
  27. Trident Super VGA 芯片组
  28. Tseng Labs Super VGA 芯片
  29. 天堂超级 VGA 芯片
  30. 威特克
于 2009-02-12T02:38:37.897 回答
1

This site: http://server.oersted.dtu.dk/www/sn/31002/?Materials/vga/main.html

Has a pretty good discussion on VGA.

The key to what you're asking is answered with this clip from the site: http://web.mit.edu/6.111/www/s2004/NEWKIT/vga.shtml

"As with RS-232, the standard for VGA video is that there are lots of standards. Every manufacturer seems to list different timings in the manuals for their monitors. The values given in the table above are not particularly critical. On a CRT monitor, the lengths of the front and back porches control the position of the image on the display. If the image appears offset to the right or left, or up or down, try adjusting the front and back porch values for the corresponding direction (or use the image position adjustments on the monitor, which accomplish the same thing)."

The problem is backwards compatability doesn lend itself well to a simple equation to determine these values. There is a modern spreadsheet that will calculate values for monitors that use the most recent standards, but if your playing around with VGA the old analog monitors will let you do tricks that you can't do on an led type display.

Your resolution is limited to how fast the electronics can turn on and off the electron beam, but the horizonal placement is only limited by your clock and what ever phase adjustments are possible on your FPGA.

For instance you can setup 640x480 timing on your sync pulses and instead of clocking data at 25MHz you can use 100 or 200 MHz and simply require a min on time for each pixel. Effectively allowing you to smooth scroll 1/8th of the width of a pixel. You may be able to do simalar tweeking to the distance between scan line although I've never tried it.

于 2009-07-29T22:41:19.980 回答