VIS, Video Interface System
The COMX uses the RCA-CDP1869 and CDP1870 Video Interface System (VIS), consisting of the CDP1869 address and sound generator and the CDP1870 colour video generator. Not all details of these two chips are described here but can be found in the data sheets available on the COMX Club ppages
1802 Output 3 to 7 are connected to the VIS as also described as OUT 3 to OUT 7 in the VIS data sheets.
Video Memory and resolution
Connected to the CDP1869/1870 the COMX has 1KB page RAM and 2KB character RAM.
The page RAM stores the ASCII code for each character position on the screen. The screen has 960 characters where position 0 (left top corner) can be accessed by memory location @F800 (before scrolling).
The character RAM stores the character definition for each of the 128 programmable characters (6x8 pixels NTSC or 6x9 pixels PAL) and can be accessed via memory location @F400-@F7FF. Character memory can be accessed via different methods see also the VIS data sheet.
The 2KB character RAM is actually enough for 6x16 pixels which is possible to use by output commands to the VIS. Note that 2 bits (CCB0/CCB1) per character line are used to select one out of 4 colours, the other 6 bits for the 6 pixels on the screen. Each character can be shown in 2 different colour sets, selectable by the highest bit (PCB) of the character number itself. So characters 0 to 127 are the same as characters 128 to 255 in different colours. A total of 8 foreground colours are available (with a limited choice of 4 per character and 1 per line of that character) and 8 background colours (defined for the whole screen).
The screen is build up of 40 columns x 24 lines, alternatively the width and/or height of the characters can be doubled to generate 20x24, 40x12 or 20x12 all using a lower screen resolution. The default character set displays only uppercase characters.
The Screen resolution is max 240x216 pixels (PAL version). Using the programmable font (with 128 characters 6 pixels wide and 9 pixels high) each pixel of the theoretical 240x216 can NOT be individually addressed. In fact in regular PAL mode at most 128x6x9 = 6912 individual pixels can be addressed at any one time. However by using the maximum character size of 6x16, double height and double width characters a high resolution mode of 108x112 is possible using 126 characters (18x7) which almost fills the complete screen. This will also allow addressing 126x6x16 = 12096 individual pixels. The only software I know of that ever used this mode is ‘F&M Super Plot+’ (see screen shot) and ‘F&M Pixel Drawing’.
PAL/NTSC Selection
The COMX will automatically select operation in PAL or NTSC first of all by the PAL/NTSC input on the VIS. During start-up the system ROM will detect PAL/NTSC by checking EF2. EF2 will give PAL/NTSC information before the first pulse on the Q line, after this EF2 will be used for keyboard handling.
Timing
The VIS runs on 5.626 MHz for a PAL and 5.67 MHz for an NTSC computer. This frequency is divided by 2 and output via CPUCLK (pin 38) to the CDP 1802 for timing of the CPU (2.813 and 2.835 Mhz). The VIS is also responsible for the timing of the interrupt (50/60 Hz) and timing of the non display period via PREDISPLAY (pin 1). Video memory can only be accessed during the non display period which allows for execution of 2160 machine cycles on a PAL and 1574 on an NTSC computer. Provided that not more instructions are executed than the indicated maximum number of machine cycles video memory can be accessed during the interrupt routine. Alternatively the program can be paused by waiting for a non display period by checking EF1.
Colours
The 8 foreground colours are defined by PCB, CCB0 and CCB1 as defined in the table below. The RGB function of PCB, CCB0 and CCB1 is depending on COLB1 and COLB0 which are set by OUT 3 bit 5 (COLB0) and 6 (COLB1).
PCB is specified by bit 7 of the character number, and CCB0 and CCB1 are specified by character memory bits 6 and 7.
C0LB1 |
COLBO |
RED |
BLUE |
GREEN |
0 |
0 |
CCBO |
CCB1 |
PCB |
0 |
1 |
CCBO |
PCB |
CCB1 |
1 |
0 |
PCB |
CCBO |
CCB1 |
1 |
1 |
PCB |
CCBO |
CCB1 |