C O M M O D O R E S E M I C O N D U C T O R 73 D E | 22^4173 0000133 4 D ~33~09 C o m m o d o r e S e m ic o n d u c t o r G r o u p c = q subsidiary of Commodore Business Machines, Inc. 6 5 6 7 VIDEO IHTKRFACE CHIP SPECIFICATION SHEET General Description; The 6567 Video Interface Chip (VIC II) is a multi-purpose video controller for use in both computer video terminals and video game applications. The color video display is 25 rows of 40 characters each with additional features including horizontal and vertical scroll, bit map graphics and movable image blocks (MIBS). Featur es: Pin Configuration o Mask programmable sync, generation, 6567 NTSC - 6567, PAL - 6569, PAL-N-6572, PAL-M-6573. DB6 I 01 40 - Vcc DBS 02 39 - DB07 DB4 J 03 38 - DB08 DB3 - 04 37 - DB09 o 47 Addressable control registers. DB2 . 05 36 - DB13 0B1 . 36 35 -■ DB11 DB0 07 34 - A10 nsr 08 33 A39 o Fully expandable system with up to LP in 09 32 - - A08 16K byte display memory. C5 / - 10 31 - A07 R/W - 11 30 - A06 Cl') BA - 12 29 - A05 (A13) Vdd 13 28 ACM (A12) o On chip color generation (16 colors) - - Coloc out 14 27 - A93 (All) Sync/Lun 15 26 - A0 2 (A10) AEC - 16 25 - A01 (A09) o Up to eight independent movable image PH0 - 17 24 - A00 (A08) blocks (MIBS). roc* 18 23 - All cs? 19 22 - Video Clock in VS3 20 21 - Color Cloclc in o Light gun/pen for target games. (Multiplexed addresses in parentheses) 950 Rittenhouse Road. Norristown, PA 19403 • 215/666-7950 • TWX 510-660-4168 C O M M O D O R E S E M I C O N D U C T O R 73 D E | B E T 4 1 7 3 0 0 0 0 1 3 4 h | “D 7 ^ 5 ^p.3 3 . CHARACTER DISPLAY MODE In the character display mode, the 6567 fetches CHARACTER POINTERS from the VIDEO MATRIX area of memory and translates the pointers to character dot addresses in the 2,048 byte CHARACTER BASE area of memory. The video matrix is comprised of 1,000 consecutive locations in memory which each contain an eight bit character pointer. The location of the video matrix within memory is defined by bits VM13-VM10 in register 24 ($18) which are used as the 4 MSB of the video matrix address. The lower order 10 bits are provided by an internal couiter (VC9-VC0) which steps through the 1000 character locations. Note that the 6567 provides only 14 address outputs so additional system hardware may be required for complete systan memory decodes. fflARACTER POINTER ADDRESS A13 A12 All A10 A09 A08 A07 A06 A05 A04 A03 A02 A01 A00 CB13 CB12 CB11 VM10 VC9 VC8 VC7 VC6 VC5 VC4 VC3 VC2 VC1 VC0 The eight bit character pointer permits 256 different .character definitions to be available simultaneously. Each character is an 8x8 matrix of dots stored in the character base as eight consecutive bytes. The location of the character base is defined by bits CB13-CB11 in register 24 ($18) which are used for the 3 most significant bits (MSB) of the character base address. The 11 lower order addresses are formed by the 8 bit character pointer from the video matrix (D7-D0) which selects a particluar character, and a 3 bit raster counter (RC2-RC0) which selects one of the eight character bytes. The resulting characters are formated as 25 rows of 40 characters each. In addition to the 8 bit character pointer, a 4-bit COLOR NYBBLE is associated with each video matrix location (the video matrix memory is 12 bits wide) which selects one of sixteen colors for each character. PHARACTFR DATA AHDPRfifi A13 A12 All A10 A09 A08 A07 A06 A05 A04 A03 A02 A01 A00 CB13 CB12 CB11 D7 D6 D5 D4 D3 D2 Dl D0 RC2 RC1 RC0 TITL* COMMODORE IC, LSI, Video Controller SIZt DRAWING NO* MV A 31801U 1 SCALS shut 2 or 22 C O M M O D O R E S E M I C O N D U C T O R 73 D E j 5 5 1 4 1 7 3 D 0 0 0 1 3 S fl ^ 3 'C < ] EXTENDED COLOR CHARACTER MODE The extended color mode allows the selection of individual background colors for each character region while maintaining the normal 8 x 8 character resolution. This mode is selected by setting the-BCM bit of register 17 ($11) to "1M. The character dot data is displayed similar to the standard mode except the 2 MSB of the character pointer are used to select the background color for each character region. ’ ’ ’ v' i»» CHAR POINTER MS BIT PAIR BACKGROUND'COLOR DISPLAYED 00 Background #0 color (register 33 ($21)) 01 Background #1 color (register 34 ($22)) 10 Background #2 color (register 35 ($23)) 11 Background #3 color (register 36 ($24)) Since the two MSB of the character pointers are used for color information, only 64 different character definitions are available. The 8562 forces CB10 and QB9 to "0" regardless of the original pointer values, so that only the first 64 character definitions are accessed. In extended color mode, each character can select one of sixteen individually defined foreground colors and one of the four available background colors. EXTENDED COLOR MODE AND MULTI-COLOR MODE CAN NOT BE ENABLED SIMULTANEOUSLY. BIT MAP MODE In bit map mode, the 6567 fetches data from memory to create a one-to-one correspondence between each displayed dot and memory bit. The bit map mode- provides a screen resolution of 320H x ' 200V individually controllable display dots. Bit map mode is selected by setting the BMM bit in register 17 ($11) to a ”1". The VIDEO MATRIX is accessed as in character mode, but the video matrix data is interpreted as color data rather than as character pointers. The VIDEO MATRIX COUNTER is also used to create the address to fetch the dot data for display from the 3,000 byte DISPLAY BASE. The display data address is formed as follows: BIT MAP DATA ADDRESS A13 A12 All A10 A09 A08 A07 A06 A05 A04 A03 A02 A01 A00 CB13 VM9 VM8 VM7 VM6 VM5 VM4 VM3 VM2 VMl VM0 RC2 RC1 RC0 VMx denotes the video matrix counter outputs, RCx denotes the 3 bit raster line counter and CB13 is from register 24 ($18). The raster counter increments once each horizontal video line (raster line)and the video matrix counter increments once every eight lines. This address sequence causes each 8x8 dot block of the video display to reflect eight sequential memory locations. TITL1 COMMODORE IC , L S I, Video C o n tr o lle r SOS e o s < I i MV A 31801U / •CALI |SHtST 1* Of 22 _ C O M M O D O R E S E M I C O N D U C T O R 73 D E | 2 5 1 4 1 7 3 □□0013b 0 D^/tT^ -33'09 STANDARD BIT MAP MODE In the standard bit map mode, color information is derived only fran the data stored in the video matrix (the color nybble is disregarded),. These 8 bits are divided into two 4-bit nybbles, allowing two colors to be selected independently in each 8x8 dot block. Whan a bit in the display memory is a "0", the color of the output dot is set by the least significant (lower) nybble (LSN). Similarly, a display memory bit of "1" selects the output color specified by the MSN (upper nybble). DISPLAY BIT DISPLAY COLOR 0 Lower nybble of video matrix pointer 1 Upper nybble of video matrix pointer MULTI-COLOR BIT MAP MODE Multi-colored bit map mode is selected by setting the MCM bit in register 22 ($16) to a "1" in conjunction with the B W bit. Multi-color mode utilizes the same memory addressing sequence as standard bit map mode, but interpretes the display dot data differently. DISPLAY BIT PAIR DISPLAY COLOR 00 Background #0 color (register 33 ($21)) 01 Upper nybble of video matrix pointer 10 Lower nybble of video matrix pointer 11 Video matrix color nybble Note that the color nybble (DB11-DB8) IS used for the multi-color bit map mode. As in character multi-color mode, the horizontal dot size is doubled since two bits are required for color selection, resulting in a screen resolution of 160H x 200V. Utilizing multi-color bit map mode, three independently selected colors can be displayed in each 8 x 8 block in addition to the background color. TITLI • COMMODORE IC , L S I, Video C o n tr o lle r size ORAWINa NO* ftiv A 31801U / 9CALI 8HCKT 5 OP 22. C O M M O D O R E S E M I C O N D U C T O R 73 D E | 25^4173 0000137 1 MOVABLE IMAGE BLOCKS The movable image block (MIB) is a special type of display image which can be displayed at any screen position without the 8x8 dot block constraints inherent in character and bit map modes. Up to 8 unique MIBs can be displayed simultaneously, each defined by 63 bytes in memory displayed as a 24x21 dot array (shown below). A nonber of special features make MIBs especially suited for video graphics and game applicatons. BYTE BYTE BYTE 00 01 02 03 04 05 57 58 59 60 61 62 MIB OISPEAY BLOCK MIB ENABLE Each MIB can be selectively enabled for display by setting its corresponding enable bit (MnE) to "1”in register 21 ($15). If the MnE bit is "0", the MIB will not be displayed. MIB POSITION Each MIB is positioned via its X and Y position register (see register map 1.3) within 512 horizontal and 256 vertical positions. The position of a MIB is specified by the upper-left corner of the array. X locations 23 to 347 ($17-5157) and Y locations 50 to 249 ($32-$F9) are visible. Since not all available MIB positions are entirely visible on the screen, MIBs may be moved smoothly on and off the display screen . TfTL* COMMODORE IC, LSI, Video Controller 8IZI DltAWMa HO* MV A 318014 / •CALI SHI IT 6 W 22 C O M M O D O R E S E M I C O N D U C T O R ~?3 D E j 5 2 1 4 1 7 3 D D D D 1 3 S 3- r ^r-5^-33^09 M IB COLOR A seperate 4-bit register is associtated with each MIB to specify the MIB color. There ate two MIB colot nodes. STANDARD MIB COLOR In the standard mode, a "0" bit of MIB data allows any background, character or bit map data to show through (transparent) and a "1" bit is displayed £s the MIB color determined by the corresponding MIB Color register. MULTI-COLOR MIB Each MIB can be individually specified to be multi-color via MnMC bits in the MIB multi-color register 28 ($1C). When the MnMC bit is H1H, the corresponding MIB is displayed in the multi-color mode. In the multi color mode, the MIB data is interpreted in pairs as in the other multi-color modes. MIB BIT PAIR COLOR DISPLAYED 00 Transparent (background data) 01 MIB Multi-color 40 (register 37 ($25)) 10 MIB Color (registers 39-46 ($27-$2E)) 11 MIB tolti-color #1 (register 38 ($26)) Since two bits of data are required for each color, the resolution of the MIB is reduced to 12 H x 21 V. Each horizontal dot is expanded to twice the standard size so that the size of the overall MIB does not change. Up to 3 colors can be displayed in each MIB (in addition to transparent), but the two colors specified by the MIB multi-color registers are shared among all 8 MIBs. M IB MAGNIFICATION Each MIB can be independently expanded (2X) in both the horizontal and vertical directions. Two registers contain the control bits (MiXE,MnYE) for the magnification control. RESIGTER ‘ FUNCTION 29 ($1D) Horizontal expand (MiXE) "lH*expand; "0"*normal 23 ($17) Vertical expand (MnYE) "1"-expand; "0"-normal No increase in resolution is realized by expanding the MIBs. The same 24x21 array (or 12x21 if multi-colored) is displayed except but the size of each dot is doubled in the desired direction (up to 4X standard dot dimension if a MIB is both multi-colored and expanded). Tim s COMMODORE IC , L S I , Video C o n tr o lle r SIZK oRAwma NOk HIV A 318014 1 •CALI ]8M««T 7 O P 22 C O M M O D O R E S E M I C O N D U C T O R 73 DE| 5 5 ^ 1 7 3 □□□0131 5 | ~ MIB PR IO R IT Y The priority of each MIB may be individually controlled with respect to the other displayed information (from character or bit map modes).. The priority of each MIB is set by the corresponding bit (MnDP) of register 27 (SIB). BIT PRIORITY 0 MIB data displayed'instead of any data (in front) 1 MIB data displayed only instead of Bkgd #0 or multi-color bit pair 01 (behind) MIB data bits of "0" always permit any other information to be displayed (i.e. MIB transparent sections). The MIBs have a fixed priority with respect to each other, with MIB 0 having the highest priority (in front) and MIB 7 the lowest (behind). When MIB data (except transparent data) of two MIBs are co-incident, the data from the lower number MIB will be displayed. COLLISION DETECTION Two types of MIB collision (co-incidence) are detected, MIB to MIB collision and MIB to display data collision. M IB TO MIB COLLISION A collision between two MIBs occurs when non-transparent output data of two MIBs are co-incident. Co-incidence of MIB transparent areas will not generate a collision. When a collision occurs, the MIB bits (ttiM) in the MIB-MIB COLLISION register 30 ($1E) will be set to "1" for each colliding MIB. The collision bits ranain set until a read of the collision register, when they are automatically cleared. MIBs collisions are detected even if off screen, behind the border. M IB TO DATA COLLISION A second register, MIB-DATA COLLISION register 31 ($1F) also contains a bit (MiD) for each MIB which is set to "1" when both the MIB and display data are co-incident. Again, the co-incidence of MIB transparent data and/or display background does not generate a collision. For special applications, the display data from the 0-1 multicolor bit pair also does not cause a collision. This feature permits their use as background display data without interfering with true MIB collisions. A MIB-DATA collision can occur off-screen in the horizontal direction if display data has been scrolled to an off-screen position (see scrolling). The MIB-DATA COLLISION register also automatically clears when read. TITUI COMMODORE IC , L S I, Video C o n tr o lle r DRAWMO NO* RKV 8? 8 318014 sh sct d or 2 i / 9CAIS COMMODORE M IB COLLISION INTERRUPTS The collision interrupt latches are set whenever the first bit * of either register is set to "1M. Once any collision bit within a register is set high, subsequent collisions will not set the interrupt latch until that collision register has been cleared to all "CTs by a read. M IB MEMORY ACCESS The data for each MIB is stored in 63 consecutive bytes of memory. Each block of MIB data is defined by a MIB pointer, located at the end of the VIDEO MATRIX. Since only 1,000 bytes of the video matrix are used in the normal display modes video matrix locations 1016-1023 ($3F8-$3FF) are used for MIB pointers 0-7 respectively. The eight bit MIB pointer from the video matrix together with the six bits from the MIB byte counter to count through the 63 bytes define the entire 14-bit address field. MIB DATA ADPRESS A13 A12 All A10 A09 A08 A07 A06 A05 A04 A03 A02 A01 A00 MP7 MP6 MP5 MP4 MP3 MP2 MPl MP0 MC5 MC4 MC3 MC2 MCI MC0 The MPx are the MIB pointer bits from the video matrix and MCx are the internally generated MIB counter bits. The MIB pointers are read from the video matrix at the end of every raster line. When the Y position register of a MIB matches the current raster line count, the actual fetches of MIB data begin. Internal counters automatically step through the 63 bytes of MIB data, displaying three bytes on each raster line. OTHER FEATURES SCREEN BLANKING The display screen may be blanked by setting the BLNK bit in register 17 ($11) to a H1H. when the screen in blanked, the entire screen displays the exterior color specified by register 32 ($20). When blanking is enabled, only transparent (Phase 1) memory accesses are required, permitting full processor utilization of the system bus. However, MOB data will be accessed if the MOBS are not also disabled. TITLt COMMODORE IC, LSI, Video Controller • fz i jD ftAw m a n o * ftffV — A 31801U / SC A kl SH ICT 9 OF 22 C O M M O D O R E S E M I C O N D U C T O R 73 » E | 5ET4173 OOOQ141 3 J ’~ DISPLAY ROW/COLUMN SELECT The normal display space consists of 25 cows of 40 character regions per row. For special display purposes, the display window may be reduced to 24 rows or 38 characters. There is no change in the format of the displayed information, except that characters (bits) adjacent to the exterior border area are covered by the border. - RSEL Number of rows CSEL Niihber of colunns 0 24 rows 0 38 colunns 1 25 rows 1 40 columns The RSEL bit is in register 17 ($11) and the CSEL bit is in register 22 ($16). For standard display the larger display window is normally used, while the smaller display window is normally used in conjunction with scrolling. SCROLLING The display data may be scrolled up to one character region in both the horizontal and vertical direction. When used in conjixiction with the smaller display window (above), scrolling can be used to create a smooth panning motion of display data while updating the system memory only when a new character row (or column) is required. Scrolling is also used for centering a display within the screen. BITS . REGISTER FUNCTION X2,XI,X0 -22 ($16) Horizontal position Y2,Y1,Y0 17 ($11) vertical position LIGHT PEN The light pen input latches the current screen position into a pair of registers.(LPX,LPY) on a low-going edge. The X position register 19 ($13) contains the 8 MSB of the X position at the time of transition. Since the X position is defined by a 9 bit coulter, resolution to 2 horizontal dots is provided. Similarly, the Y position is latched in its register 20 ($14) with 8 bits provide unique raster resolution within the visible display. The light pen latch may be triggered only once per frame, and subsequent triggers within the same frame will have no effect. TiTLC COM M ODORE IC , L S I, Video C o n tr o lle r 8121 DRAWING NO. R*V A 318014 / SCALS 8H8CT 10 OF 2 2 • ------ -■ .............. — .................... . - ............... C O M M O D O R E S E M I C O N D U C T O R 73 D E j 22=54173 D O Q D m a S I yT - 5 3 -3 3 -0 ? RASTER REGISTER The raster register is a dual function register. A read of the raster register 18 ($12) returns the lower 3 bits of the current raster positon (the MSB-RC8 is located in register 17 ($11)). A write to the raster bits (including RC8) is latched for use in an internal raster compare. When the current raster matches the written value, the raster interrupt latch is set. The raster register should be interrogated to prevent display flicker by delaying display changes to occur outside the visible area. The visible area of the display is from raster 51 to raster 251 ($033-$0FB). INTERRUPT REGISTER The interrupt register indicates the status of the four sources of interrupt. An interrupt latch in register 25 ($19) is set to "I" when an interrupt source has generated an interrupt request. LATCH ENABLE BIT BIT WHEN SET TRST ERST Actual raster c o m t » stored raster count IMDC EMDC MOB-DATA collision (first bit only) IftC EMMC MOB-MOB collision (first bit only) ILP . ELP First negative transition of LP per frame IRQ When IRQ/ output low To enable an interrupt request to set the IRQ/ output to •'0", the corresponding interrupt enable bit in register 26 ($1A) must be set to "I”. Once an interrupt latch has been set, the latch may be cleared only by writing a "1" to the associated bit in the interrupt register. This feature allows selective handling of video interrupts without software storing of the active interrupts. DYNAMIC RAM REFRESH A dynamic ram refresh controller is built in to the 6567 device. Five 8-bit row addresses are refreshed every raster line. This rate guarantees a maximum delay of 2.02 ms between the refresh of any single row address in a 128 refresh scheme. (The maximum delay is 3.66ms in a 256 address refresh scheme). This refresh is totally transparent to the system, since the refresh occurs during Phase 1 of the system clock. The 6567 generates both SAS/ and CAS/ which are normally connected directly to the dynamic rams. RAS/ and CAS/ are generated for every Phase 2 and every video data access (including refresh) so that external clock generation is not required. T im COMMODORE IC , 1 5 1 , V ideo C o n tr o lle r 8B I lOAAWIMO NOk RKV A 1 318014 / 8CAL8 |SHf«T n 0* 22 C O M M O D O R E S E M I C O N D U C T O R 73 D E | 5214173 DDOD143 7 1 ~ T ^ 5 ^ T 3 3 ^ 0 ^ COLOR CODE TABLE OB11 OB10 DB09 DB08 HEX COLOR 0 0 . 0 0 $0 Black .0 0 0 I $1 White 0 ■0• 1 0 $2 Red 0 0 1 1 $3 Cyan 0 •v -A ■. 0 0 $4 Purple 0 ,1 ' 0 1 $5 Green 0 l 1 0 56 -Blue 0 l 1 1 S7 Yellow 1 0 0 0 $8 Orange 1 0 0 1 $9 Brown 1 0 1 0 $A Light Red 1 0 1 1 SB Dark Grey 1 l 0 0 $C Medium Grey 1 l 0 1 $D Light Green 1 l 1 0 $E Light Blue 1 l 1 1 $F Light Grey TITLI COMMODORE IC, LSI, Video Controller [SBC CHAWING HOk mv A 313014 / SCALI S H **T 1 2 OP 22 C O M M O D O R E S E M I C O N D U C T O R 73 D E | 5 2 1 4 1 7 3 0 D 0 0 1 4 4 1 ^ y resistor. VIEDO INTERFACE The video output frcro the 6567 consists of two signals which must be externally mixed together to create NTSC compatible composite video. After appropriate mixing, the resulting signal can directly drive a video monitor or RF modulator for use with a standard television. VIDEO CLOCK IN This clock input is the fundamental dot shift rate clock. In addition, all other video sync and system interface signals are derived by dividing this clock. Normally, the desired frequency is 9 Mhz. The primary constaints are the system timing and the requirement that one horizontal raster line is 520 video clock cycles. COLOR CLOCK IN The color clock is used to derive the chrananince signal. NTSC video systems require this input to be 14.31818 Mhz. This base frequency is divided by 4 internally and then appropriately phase shifted to create the 3.5795 Mhz video color signal for NTTSC applications. SYNC/LUM OUTPUT SYNC/LUM output from the 6567 contains all the video data, including horizontal and vertical syncs, as well as the luninancJe information of the video display is an open drain output requiring an external pullup of 500 ohms. COLOR OUTPUT The COLOR output contains all the chrominance information, including the color reference burst and the color of all display data. The COLOR output is open source and should be terminated with 1,000 ohms to ground. TITLI COMMODORE IC, LSI, Video Controller StZI IDRAWIMQ NO* ftSV ...■ — A 318014 1 9CALS 8 HC8 T 17 OP 22 C O M M O D O R E S E M I C O N D U C T O R 73 DE | 2 2 ^ 4 1 7 3 0 D D 0 1 4 T fl | ~ ^ T ^ S Q ^ 3 ^ 7 o ^ ELECTRICAL REQUIREMENTS ABSOLUTE MAXIMUM RATINGS Stresses above those listed may cause permanent damage to the circuit. This is a stress rating only. Functional operation of the device at these or any condtions other than those indicated in the operational sections of this specification is not implied. Characteristic Min Max Units Ambient temerature under bias -25 +125 Deg. C. Storage temerature -65 +150 Deg. C. Applied Supply voltage Vcc -0.5 +7.0 Volts Applied Output voltage -0.5. +5.5 Volts Applied Input voltage -0.5 +7.0 volts Applied Supply Volt. VDD ~0 •5 +15.0 Volts OPERATING CONDITIONS All electrical characteristics (A.C. and D.C.) are specified over the entire range of the operating conditious 'unless specifically noted. Condition Min Max units Supply Votage (Vcc) 4.75 5.25 Volts Supply Free Air Temperature 0 50 Deg. C. Min - I I .4V Dot Clock cycle 122 123 ns Max-12.6V Dotclk lo pulse in 60 - ns Dotolk hi pulse in 45 - ns Color Clock frequency 14.317 14.319 MHZ Colorclk lo pulse in 25 - ns Colorclk hi pulse in 25 - ns D.C. CHARACTERISTICS Characteristic Symbol Min Max Units Test Conditions — — — —— 3.3.1 Input high level Vih 2.0 VCC Volts 3.3.2 Input low level Vil -0.5 0.8 VOltS 3.3.3 Output High level Voh 2.4 - VOltS Ioh * -200uA 3.3.4 Output &ow level Vol - 0.4 volts Iol 3 3.2mA 3.3.6 I/O Leakage 11kg -10 .10 uAmps 0.4V