1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/vga.h Sun May 28 19:03:58 2017 +0200
1.3 @@ -0,0 +1,19 @@
1.4 +#ifndef __VGA_H__
1.5 +#define __VGA_H__
1.6 +
1.7 +#define LINE_LENGTH 160 /* pixels */
1.8 +#define LINE_COUNT 256 /* distinct display lines */
1.9 +
1.10 +#define HFREQ_LIMIT 643 /* 24MHz cycles */
1.11 +#define HSYNC_START 460 /* 24MHz cycles */
1.12 +#define HSYNC_LIMIT 64 /* 24MHz cycles */
1.13 +#define HSYNC_END (HSYNC_START + HSYNC_LIMIT)
1.14 +
1.15 +#define VISIBLE_START 70 /* horizontal lines, back porch end */
1.16 +#define VFP_START (VISIBLE_START + 2 * LINE_COUNT)
1.17 +#define VSYNC_START 620 /* horizontal lines, front porch end */
1.18 +#define VSYNC_END 622 /* horizontal lines, back porch start */
1.19 +
1.20 +#define SCREEN_SIZE (40 * 1024)
1.21 +
1.22 +#endif /* __VGA_H__ */