branches/new_menus/src/mess/drivers/fanucspmg.c
| r29424 | r29425 | |
| 2 | 2 | // copyright-holders:R. Belmont |
| 3 | 3 | /*************************************************************************** |
| 4 | 4 | |
| 5 | | Fanuc System P Model G |
| 5 | Fanuc System P Model G |
| 6 | Fanuc 1983 |
| 6 | 7 | |
| 7 | | 2014-03-22 Skeleton driver. |
| 8 | 2014-03-22 Skeleton driver. |
| 9 | This is a machine from 1983 in a single case |
| 10 | with a lot of ports and a unique keyboard. |
| 8 | 11 | |
| 9 | | This is a machine from 1983 in a single case with a |
| 10 | | lot of ports and a unique keyboard. |
| 11 | | |
| 12 | | Also known as Fanuc P-G System, this is a dedicated 8085+8086+8087-based computer |
| 13 | | system running software for CNC Programming. |
| 14 | | The system boots up from ROM and then application software is loaded from floppies. |
| 15 | | The softwares are not point and click auto-generation type conversational CAD/CAM |
| 16 | | applications. |
| 17 | | The earlier 'non-Symbolic' software requires knowledge of programming in APT and other |
| 18 | | languages of the era. The 'Symbolic' software has menus and asks questions and the blanks |
| 19 | | must be filled in correctly. The graphics are mostly made of lines but are |
| 20 | | sufficient to complete the task easily. Efficient and effective use of this system |
| 21 | | requires deep knowledge of CNC Machining techniques (Turning/Milling etc) and a |
| 22 | | good understanding of machining processes and procedures. With correct usage this system |
| 23 | | can be used to create CNC G-Code programs for any part that can be manufactured on a |
| 24 | | CNC Machine. Because the system is made in Japan in the early 80's and the manuals are |
| 25 | | very technical it also requires some skill in deciphering Japanese-English translated |
| 26 | | technical texts to understand how to use it properly. |
| 12 | Also known as Fanuc P-G System, this is a dedicated 8085+8086+8087-based computer |
| 13 | system running software for CNC Programming. |
| 14 | The system boots up from on-board EPROM and shows a big ASCII-art boot screen |
| 15 | FANUC SYSTEM P MODEL G and the ROM software version in the lower right corner. |
| 16 | To initiate booting from the floppy drive hold down the LOAD key for 3-5 seconds. |
| 17 | The system checks for a long LOAD key press so that it doesn't load software |
| 18 | if the LOAD key is accidentally pressed quickly while using the system, which would |
| 19 | erase everything in memory and all data up to that point and re-load the software from |
| 20 | scratch. When loading is activated application software is read from floppies. |
| 27 | 21 | |
| 28 | | The box housing everything is 20" wide by 20" deep by 12" high and weighs |
| 29 | | approximately 40 pounds. Power input is 85VAC to 110VAC. For the non-US and |
| 30 | | non-Japanese markets a separate dedicated power supply is provided and is 12" |
| 31 | | wide by 8" deep by 10" high and weighs approximately 20 pounds. |
| 22 | The softwares are not point and click auto-generation type conversational CAD/CAM |
| 23 | applications. The earlier 'non-Symbolic' software requires knowledge of programming in APT |
| 24 | and other languages of the era. The 'Symbolic' software has menus and asks questions and |
| 25 | the blanks must be filled in correctly. The graphics are mostly made of lines but are |
| 26 | sufficient to complete the task easily. Efficient and effective use of this system |
| 27 | requires deep knowledge of CNC Machining techniques (Turning/Milling etc) and a |
| 28 | good understanding of machining processes and procedures. With correct usage this system |
| 29 | can be used to create CNC G-Code programs for any part that can be manufactured on a |
| 30 | CNC Machine. Because the system is made in Japan in the early 80's and the manuals are |
| 31 | very technical it also requires some skill in deciphering Japanese-English translated |
| 32 | technical texts to understand how to use it properly. |
| 32 | 33 | |
| 33 | | A number of optional peripherals can connect to it including a Fanuc Printer, |
| 34 | | Fanuc PPR Unit (Paper tape Puncher/Reader with built-in printer), Fanuc Program |
| 35 | | File (containing a 20MB HDD, two 8" floppy drives and two RS232 ports), Fanuc Cassette |
| 36 | | Adapter, XY Plotter (A3 or A1), Fanuc Digitizing Tablet (A3 or A0) and Fanuc I/O Selector Box. |
| 34 | The box housing everything is 20" wide by 20" deep by 12" high and weighs |
| 35 | approximately 40 pounds. Power input is 85VAC to 110VAC. For the non-US and |
| 36 | non-Japanese markets a separate dedicated power supply is provided and is 12" |
| 37 | wide by 8" deep by 10" high and weighs approximately 20 pounds. |
| 37 | 38 | |
| 38 | | The P-G System has an internal 12" color monitor and dual 5 1/4" floppy drives. |
| 39 | | A later model was released in 1986 called the Mark II using dual 3 1/2" floppy |
| 40 | | drives. The previous version was SYSTEM P MODEL D. It had a 12" green monochrome |
| 41 | | monitor and booted from, and stored to, a cassette tape or floppy disk. |
| 39 | A number of optional peripherals can connect to it including a Fanuc Printer, |
| 40 | Fanuc PPR Unit (Paper tape Puncher/Reader with built-in printer), Fanuc Program |
| 41 | File (containing a 20MB HDD, two 8" floppy drives and two RS232 ports), Fanuc Cassette |
| 42 | Adapter, XY Plotter (A3 or A1), Fanuc Digitizing Tablet (A3 or A0) and Fanuc I/O Selector Box. |
| 42 | 43 | |
| 43 | | The screen resolution is 512 x 384 pixels. |
| 44 | | It can display 64 characters x 24 lines. |
| 44 | The P-G System has an internal 12" color monitor and dual 5 1/4" floppy drives. |
| 45 | A later model was released in 1986 called the Mark II using dual 3 1/2" floppy |
| 46 | drives. The previous version was SYSTEM P MODEL D. It had a 12" green monochrome |
| 47 | monitor and booted from, and stored to, a cassette tape or floppy disk. |
| 45 | 48 | |
| 46 | | The floppy format is custom. Floppies are double sided double density and |
| 47 | | regular PC DSDD 360k floppies can be used after they are formatted using the |
| 48 | | P-G System. |
| 49 | | The floppy geometry is 40 tracks, 16 sectors per track, 256 bytes per sector |
| 50 | | and 2 sides for a total storage capacity of 327680 bytes. |
| 51 | | The floppy drives are typical PC-type 5 1/4" 360k drives and were manufactured |
| 52 | | by Y-E DATA, model YD-580. |
| 49 | The screen resolution is 512 x 384 pixels. |
| 50 | It can display 64 characters x 24 lines. |
| 53 | 51 | |
| 54 | | The floppy disks can be backed-up and imaged using a DOS program called ImageDisk |
| 55 | | which is available here..... |
| 56 | | http://www.classiccmp.org/dunfield/img/index.htm |
| 57 | | With a 5 1/4" HD floppy drive, in the GUI in settings change the number of |
| 58 | | cylinders to 40, translate speed 300 -> 250 (to read a DD disk on a HD drive). |
| 59 | | On the main menu press R to Read, type a file-name and press enter, press enter |
| 60 | | again to skip the comment. Press enter again and it will read the disk and save |
| 61 | | it to the HDD. |
| 52 | The floppy format is custom. Floppies are double sided double density and |
| 53 | regular PC DSDD 360k floppies can be used after they are formatted using the |
| 54 | P-G System. |
| 55 | The floppy geometry is 40 tracks, 16 sectors per track, 256 bytes per sector |
| 56 | and 2 sides for a total storage capacity of 327680 bytes. |
| 57 | The floppy drives are typical PC-type 5 1/4" 360k drives and were manufactured |
| 58 | by Y-E DATA, model YD-580. |
| 62 | 59 | |
| 63 | | The following is a complete list of software titles available. |
| 64 | | The info is taken from a glossy sales brochure printed in July 1985. |
| 65 | | Other versions did exist so this list is not final. |
| 66 | | * denotes it is dumped. All other titles are not dumped and are needed. |
| 60 | The floppy disks can be backed-up and imaged using a DOS program called ImageDisk |
| 61 | which is available here..... |
| 62 | http://www.classiccmp.org/dunfield/img/index.htm |
| 63 | With a 5 1/4" HD floppy drive, in the GUI in settings change the number of |
| 64 | cylinders to 40, translate speed 300 -> 250 (to read a DD disk on a HD drive). |
| 65 | On the main menu press R to Read, type a file-name and press enter, press enter |
| 66 | again to skip the comment. Press enter again and it will read the disk and save |
| 67 | it to the HDD. |
| 67 | 68 | |
| 68 | | Language Input - |
| 69 | The following is a complete list of software titles available. |
| 70 | The info is taken from a glossy sales brochure printed in July 1985. |
| 71 | Other versions did exist so this list is not final. |
| 72 | * denotes it is dumped. All other titles are not dumped and are needed. |
| 69 | 73 | |
| 70 | | Title Part Number |
| 71 | | -------------------------------- |
| 72 | | FAPT TURN A08B-0033-J600#E |
| 73 | | FAPT CUT A08B-0033-J620#E |
| 74 | | FAPT MILL A08B-0033-J640#E |
| 75 | | FAPT DIE-II A08B-0033-J660#E |
| 76 | | FAPT PUNCH-I A08B-0033-J520#E |
| 77 | | FAPT PUNCH-II A08B-0033-J700#E |
| 78 | | FAPT HELICAL A08B-0033-J642#E |
| 79 | | FAPT POST A08B-0033-H642#E |
| 80 | | *FAPT POST A08B-0031-H630 Edition C 85/1/31 |
| 74 | Language Input - |
| 81 | 75 | |
| 76 | Title Part Number |
| 77 | -------------------------------- |
| 78 | FAPT TURN A08B-0033-J600#E |
| 79 | FAPT CUT A08B-0033-J620#E |
| 80 | FAPT MILL A08B-0033-J640#E |
| 81 | FAPT DIE-II A08B-0033-J660#E |
| 82 | FAPT PUNCH-I A08B-0033-J520#E |
| 83 | FAPT PUNCH-II A08B-0033-J700#E |
| 84 | FAPT HELICAL A08B-0033-J642#E |
| 85 | FAPT POST A08B-0033-H642#E |
| 86 | *FAPT POST A08B-0031-H630 Edition C 85/1/31 |
| 82 | 87 | |
| 83 | | Graphic Input - |
| 84 | 88 | |
| 85 | | Title Part Number |
| 86 | | -------------------------------------- |
| 87 | | *Symbolic FAPT TURN A08B-0033-J800#E +English |
| 88 | | Symbolic FAPT MILL A08B-0033-J840#E |
| 89 | | Symbolic FAPT DRILL A08B-0033-J860#E |
| 90 | | Symbolic FAPT CUT A08B-0033-J820#E |
| 91 | | FAPT DIGITIZER A08B-0033-J510#E |
| 89 | Graphic Input - |
| 92 | 90 | |
| 93 | | + Symbolic FAPT TURN was available in English, German, French, Dutch, Finnish, |
| 94 | | and Swedish versions. |
| 91 | Title Part Number |
| 92 | -------------------------------------- |
| 93 | *Symbolic FAPT TURN A08B-0033-J800#E +English |
| 94 | Symbolic FAPT MILL A08B-0033-J840#E |
| 95 | Symbolic FAPT DRILL A08B-0033-J860#E |
| 96 | Symbolic FAPT CUT A08B-0033-J820#E |
| 97 | FAPT DIGITIZER A08B-0033-J510#E |
| 95 | 98 | |
| 99 | + Symbolic FAPT TURN was available in English, German, French, Dutch, Finnish, |
| 100 | and Swedish versions. |
| 96 | 101 | |
| 97 | | Support System - |
| 98 | 102 | |
| 99 | | Title Part Number |
| 100 | | ------------------------------- |
| 101 | | *FAPT TRACER A08B-0033-H620#E Edition B 85/1/16 |
| 102 | | *FAPT TEACHER A08B-0033-J610#E Edition B 85/1/12 |
| 103 | | *FAPT DOCTOR A08B-0033-J600#E Edition B 84/12/21 |
| 103 | Support System - |
| 104 | 104 | |
| 105 | Title Part Number |
| 106 | ------------------------------- |
| 107 | *FAPT TRACER A08B-0033-H620#E Edition B 85/1/16 |
| 108 | *FAPT TEACHER A08B-0033-J610#E Edition B 85/1/12 |
| 109 | *FAPT DOCTOR A08B-0033-J600#E Edition B 84/12/21 |
| 105 | 110 | |
| 106 | | The software for the Fanuc System P Model G is extremely rare now and very |
| 107 | | difficult to find. If you do have any of these wanted software titles or any manuals |
| 108 | | listed below and want to help please contact me (Guru) via http://mamedev.org/contact.html |
| 109 | 111 | |
| 110 | | The following is a complete list of manuals available for the first edition of the |
| 111 | | Fanuc System P Model G released in 1983. The info is taken from a glossy sales brochure |
| 112 | | printed in July 1985. There were other manuals released later for the Mark II and |
| 113 | | updated manuals (each with a different part number). |
| 114 | | The manuals were available in Japanese and English. The part numbers listed here |
| 115 | | are English versions, denoted by the E at the end of the part number. |
| 116 | | * denotes these manuals are secured and available in PDF format. |
| 112 | Note: To initiate booting from the floppy drive hold down the LOAD key for 3-5 seconds. |
| 117 | 113 | |
| 118 | | Description - |
| 114 | The software for the Fanuc System P Model G is extremely rare now and very |
| 115 | difficult to find. If you do have any of these wanted software titles or any manuals |
| 116 | listed below and want to help please contact me (Guru) via http://mamedev.org/contact.html |
| 119 | 117 | |
| 120 | | Title Part Number |
| 121 | | --------------------------------------- |
| 122 | | FAPT TURN/MILL Description B-54102E |
| 123 | | FAPT CUT Description B-54103E |
| 124 | | FAPT PUNCH-I Description B-54104E |
| 125 | | FAPT TRACER Description B-54106E |
| 126 | | FAPT DIGITIZER Description B-54107E |
| 127 | | Symbolic FAPT Description B-54131E |
| 128 | | FAPT DIE-II Description B-54121E |
| 118 | The following is a complete list of manuals available for the first edition of the |
| 119 | Fanuc System P Model G released in 1983. The info is taken from a glossy sales brochure |
| 120 | printed in July 1985. There were other manuals released later for the Mark II and |
| 121 | updated manuals (each with a different part number). |
| 122 | The manuals were available in Japanese and English. The part numbers listed here |
| 123 | are English versions, denoted by the E at the end of the part number. |
| 124 | * denotes these manuals are secured and available in PDF format. |
| 129 | 125 | |
| 126 | Description - |
| 130 | 127 | |
| 131 | | Operator's Manual - |
| 128 | Title Part Number |
| 129 | --------------------------------------- |
| 130 | FAPT TURN/MILL Description B-54102E |
| 131 | FAPT CUT Description B-54103E |
| 132 | FAPT PUNCH-I Description B-54104E |
| 133 | FAPT TRACER Description B-54106E |
| 134 | FAPT DIGITIZER Description B-54107E |
| 135 | FAPT DIE-II Description B-54121E |
| 136 | Symbolic FAPT Description B-54131E |
| 132 | 137 | |
| 133 | | Title Part Number |
| 134 | | ---------------------------------------------------------- |
| 135 | | System P-Model G Operator's Manual B-54111E |
| 136 | | System P-Model G Mark II Operator's Manual B-66014E |
| 137 | | *System P-Model G Operator's Manual Supplement B-54112E/03-1 |
| 138 | | FAPT TURN/MILL Operator's Manual B-54112E |
| 139 | | FAPT CUT Operator's Manual B-54113E |
| 140 | | FAPT PUNCH-I Operator's Manual B-54114E |
| 141 | | FAPT PUNCH-II Operator's Manual B-54115E |
| 142 | | *Symbolic FAPT TURN Operator's Manual B-54132E |
| 143 | | *Symbolic FAPT TURN Operator's Manual B-66025E (for System P Mark II) |
| 144 | | Symbolic FAPT MILL Operator's Manual B-54134E |
| 145 | | Symbolic FAPT DRILL Operator's Manual B-54138E |
| 146 | | Symbolic FAPT CUT Operator's Manual B-54136E |
| 147 | | FAPT DIE-II Operator's Manual B-54122E (Two Volumes) |
| 148 | | FAPT TRACER Operator's Manual B-54116E |
| 149 | | FAPT DIGITIZER Operator's Manual B-54117E |
| 150 | | FAPT TEACHER Operator's Manual B-54126E |
| 151 | 138 | |
| 139 | Operator's Manual - |
| 152 | 140 | |
| 153 | | Others - |
| 141 | Title Part Number |
| 142 | ---------------------------------------------------------- |
| 143 | *System P-Model G Operator's Manual B-54111E/03 |
| 144 | System P-Model G Mark II Operator's Manual B-66014E |
| 145 | *System P-Model G Operator's Manual Supplement B-54112E/03-1 |
| 146 | FAPT TURN/MILL Operator's Manual B-54112E |
| 147 | FAPT CUT Operator's Manual B-54113E |
| 148 | FAPT PUNCH-I Operator's Manual B-54114E |
| 149 | FAPT PUNCH-II Operator's Manual B-54115E |
| 150 | *FAPT TRACER Operator's Manual B-54116E/03 |
| 151 | FAPT DIGITIZER Operator's Manual B-54117E |
| 152 | *FAPT Universal POST Operator's Manual B-54118E/02 |
| 153 | FAPT DIE-II Operator's Manual (Volume 1) B-54122E |
| 154 | FAPT DIE-II Operator's Manual (Volume 2) B-54122E-1 |
| 155 | *FAPT TEACHER Operator's Manual B-54126E/01 |
| 156 | 220S FAPT MILL Operator's Manual B-54127E |
| 157 | *Symbolic FAPT TURN Operator's Manual B-54132E/01 |
| 158 | Symbolic FAPT MILL Operator's Manual B-54134E |
| 159 | Symbolic FAPT CUT Operator's Manual B-54136E |
| 160 | Symbolic FAPT DRILL Operator's Manual B-54138E |
| 161 | *Symbolic FAPT TURN Operator's Manual B-66025E/01 (for System P Mark II) |
| 154 | 162 | |
| 155 | | Title Part Number |
| 156 | | ----------------------------------------------------- |
| 157 | | System P-Model G Operator's Handbook B-54158E |
| 158 | | *System P-Model G Maintenance Manual B-54159E |
| 159 | | FAPT TURN/MILL/CUT Part program examples B-54128E |
| 160 | | FANUC CASSETTE Operator's Manual B-53484E |
| 161 | | *Symbolic FAPT TURN Operator's Handbook B-53034E (for System P Model D) |
| 162 | | Symbolic FAPT TURN Operator's Handbook B-54133E |
| 163 | | FAPT DIE-II Part program examples B-54123E |
| 164 | | FANUC PPR Operator's Manual B-54584E |
| 165 | 163 | |
| 166 | | Note the handbooks were pocket-sized 8" long by 3 1/2" wide and approximately 50 pages. |
| 164 | Others - |
| 167 | 165 | |
| 166 | Title Part Number |
| 167 | ----------------------------------------------------- |
| 168 | *Symbolic FAPT TURN Operator's Handbook B-53034E (for System P Model D) |
| 169 | FANUC CASSETTE Operator's Manual B-53484E |
| 170 | FAPT DIE-II Part program examples B-54123E |
| 171 | FAPT TURN/MILL/CUT Part program examples B-54128E |
| 172 | Symbolic FAPT TURN Operator's Handbook B-54133E |
| 173 | System P-Model G Operator's Handbook B-54158E |
| 174 | *System P-Model G Maintenance Manual B-54159E/01 |
| 175 | *FANUC PPR Operator's Manual B-54584E/01 |
| 168 | 176 | |
| 169 | | The unit has it's own dedicated keyboard with many special keys. |
| 170 | | The keyboard layout is shown below. |
| 177 | Note the handbooks are pocket-sized 8" long by 3 1/2" wide and approximately 50 pages. |
| 171 | 178 | |
| 172 | | |------------------------------------------------------------------------------| |
| 173 | | | | |
| 174 | | | LOAD F0 F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 F13 F14 F15 R0 R1 R2 R3 | |
| 175 | | | | |
| 176 | | | | |
| 177 | | | ! " # $ % & ' ( ) = | |
| 178 | | | K0 1 2 3 4 5 6 7 8 9 0 - ^ Y DEL 7 8 9 + | (Y is Japanese Yen sign) |
| 179 | | | | |
| 180 | | | | |
| 181 | | | K1 CAN Q W E R T Y U I O P @ [ NL BS 4 5 6 - | (NL means NEXT LINE, BS is backspace) |
| 182 | | | | (NL is equivalent to return or enter and) |
| 183 | | | + * | (forces the cursor to move to the next data entry point) |
| 184 | | | K2 UC A S D F G H J K L ; : ] UC 1 2 3 x | (UC is uppercase) |
| 185 | | | | |
| 186 | | | < > ? | |
| 187 | | | K3 LC Z X C V B N M , . / - LC 0 , . / | (LC is lowercase) |
| 188 | | | | |
| 189 | | | | |
| 190 | | | _S__P__A__C__E__B__A__R_ _N__L_ | |
| 191 | | | | |
| 192 | | |------------------------------------------------------------------------------| |
| 193 | 179 | |
| 194 | | On the numeric keypad there are directional arrows on numbers 1 2 3 4 6 7 8 9 |
| 195 | | 1 3 7 9 have arrows pointing South West, South East, North West, North East. |
| 196 | | 2 4 6 8 have arrows pointing down, left, right and up. |
| 197 | | 5 is the center and has no additional markings on it. |
| 198 | | Number 0 has an anti-clockwise 180 degrees arc with an arrow at the end and . has |
| 199 | | a clockwise 180 degrees arc with an arrow at the end. |
| 200 | | These keys are the 'Symbolic' keys. |
| 180 | The unit has it's own dedicated keyboard with many special keys. |
| 181 | The keyboard layout is shown below. |
| 201 | 182 | |
| 202 | | The F-keys and R-keys are programmed by the software that is running on the system. |
| 203 | | The F-keys are SPDT type keys so they can be either up or locked in the down position. |
| 204 | | For Symbolic FAPT TURN these keys are pre-programmed as follows..... |
| 183 | |------------------------------------------------------------------------------| |
| 184 | | | |
| 185 | | LOAD F0 F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 F13 F14 F15 R0 R1 R2 R3 | |
| 186 | | | |
| 187 | | | |
| 188 | | ! " # $ % & ' ( ) = | |
| 189 | | K0 1 2 3 4 5 6 7 8 9 0 - ^ Y DEL 7 8 9 + | (Y is Japanese Yen sign) |
| 190 | | | |
| 191 | | | |
| 192 | | K1 CAN Q W E R T Y U I O P @ [ NL BS 4 5 6 - | (NL means NEXT LINE, BS is backspace) |
| 193 | | | (NL is equivalent to return or enter and) |
| 194 | | + * | (forces the cursor to move to the next data entry point) |
| 195 | | K2 UC A S D F G H J K L ; : ] UC 1 2 3 x | (UC is uppercase) |
| 196 | | | |
| 197 | | < > ? | |
| 198 | | K3 LC Z X C V B N M , . / - LC 0 , . / | (LC is lowercase) |
| 199 | | | |
| 200 | | | |
| 201 | | _S__P__A__C__E__B__A__R_ _N__L_ | |
| 202 | | | |
| 203 | |------------------------------------------------------------------------------| |
| 205 | 204 | |
| 206 | | F0 - ON: Sets the backwards direction when using the R1 key. |
| 207 | | OFF: Sets the forwards direction when using the R1 key. Default is OFF. |
| 208 | | F1 - ON: Makes the whole screen the graphic area. |
| 209 | | OFF: Auto-calc the graphic area so the graphic does not overlap the text. Default is OFF. |
| 210 | | F2 - ON: Shows the parts figure (graphics). Default is ON. |
| 211 | | OFF: Does not show the parts figure. |
| 212 | | F3 - ON: Display the NC G-Code data on screen. Default is ON. |
| 213 | | OFF: Does not display the NC G-Code data on screen. |
| 214 | | F4 - ON: Printer ON. |
| 215 | | OFF: Printer OFF. Default is OFF. The printer can be switched on or off any time. When enabled |
| 216 | | everything displayed on the screen will also print on the printer. |
| 217 | | F5 - ON: Stops execution of the NC G-Code data before each process begins. Keyboard input additions |
| 218 | | can also be done at this time. |
| 219 | | OFF: Program execution continues to the end. Default is OFF. |
| 220 | | F6 - ON: Outputs the NC G-Code data to a separately selected medium (floppy/cassette or paper tape) |
| 221 | | OFF: No output to additional medium. Default is OFF. |
| 222 | | F7 - ON: Stops each time a line of NC G-Code data is output. This is equivalent to Single Block on a CNC Machine. |
| 223 | | OFF: Program execution continues to the end. Default is OFF. |
| 224 | | F8 - |
| 225 | | F9 - |
| 226 | | F10- ON: Sends the part figure graphic and NC G-Code data to the XY plotter |
| 227 | | OFF: No output to XY plotter |
| 228 | | F11- |
| 229 | | F12- |
| 230 | | F13- |
| 231 | | F14- |
| 232 | | F15- |
| 205 | On the numeric keypad there are directional arrows on numbers 1 2 3 4 6 7 8 9 |
| 206 | 1 3 7 9 have arrows pointing South West, South East, North West, North East. |
| 207 | 2 4 6 8 have arrows pointing down, left, right and up. |
| 208 | 5 is the center and has no additional markings on it. |
| 209 | Number 0 has an anti-clockwise 180 degrees arc with an arrow at the end and . has |
| 210 | a clockwise 180 degrees arc with an arrow at the end. |
| 211 | These keys are the 'Symbolic' keys. |
| 233 | 212 | |
| 234 | | The function of the R-keys changes depending on the application and the menu shown on the screen. |
| 235 | | The initial Symbolic FAPT TURN settings for the R-keys are.... |
| 236 | | R0 - FAPT Execution |
| 237 | | R1 - Family Program |
| 238 | | R2 - Setting |
| 239 | | R3 - Auxiliary Work |
| 213 | The F-keys and R-keys are programmed by the software that is running on the system. |
| 214 | The F-keys act like SPDT switches and can be toggled either off or on. |
| 215 | When they are on, a LED in the center of the key lights. |
| 216 | For Symbolic FAPT TURN these keys are pre-programmed as follows..... |
| 240 | 217 | |
| 218 | F0 - ON: Sets the backwards direction when using the R1 key. |
| 219 | OFF: Sets the forwards direction when using the R1 key. Default is OFF. |
| 220 | F1 - ON: Makes the whole screen the graphic area. |
| 221 | OFF: Auto-calc the graphic area so the graphic does not overlap the text. Default is OFF. |
| 222 | F2 - ON: Shows the parts figure (graphics). Default is ON. |
| 223 | OFF: Does not show the parts figure. |
| 224 | F3 - ON: Display the NC G-Code data on screen. Default is ON. |
| 225 | OFF: Does not display the NC G-Code data on screen. |
| 226 | F4 - ON: Printer ON. |
| 227 | OFF: Printer OFF. The printer can be switched on or off any time. When enabled |
| 228 | everything displayed on the screen will also print on the printer. Default is OFF. |
| 229 | F5 - ON: Stops execution of the NC G-Code data before each process begins. Keyboard input additions |
| 230 | can also be done at this time. To continue press NL. |
| 231 | OFF: Program execution continues to the end. Default is OFF. |
| 232 | F6 - ON: Outputs the NC G-Code data to a separately selected medium (floppy/cassette or paper tape) |
| 233 | OFF: No output to additional medium. Default is OFF. |
| 234 | F7 - ON: Stops each time a line of NC G-Code data is output. This is equivalent to Single Block on a CNC Machine. |
| 235 | To continue press NL. |
| 236 | OFF: Program execution continues to the end. Default is OFF. |
| 237 | F8 - |
| 238 | F9 - |
| 239 | F10- ON: Sends the part figure graphic and NC G-Code data to the XY plotter |
| 240 | OFF: No output to XY plotter |
| 241 | F11- |
| 242 | F12- |
| 243 | F13- |
| 244 | F14- |
| 245 | F15- |
| 241 | 246 | |
| 247 | The function of the R-keys changes depending on the application and the menu shown on the screen. |
| 248 | The R-keys are used for tasks within the current screen so the function of the R-keys is always |
| 249 | displayed on screen at all times. |
| 250 | The initial Symbolic FAPT TURN settings for the R-keys are.... |
| 251 | R0 - FAPT Execution |
| 252 | R1 - Family Program |
| 253 | R2 - Setting |
| 254 | R3 - Auxiliary Work |
| 242 | 255 | |
| 243 | | Box Layout (top view) |
| 244 | | ---------- |
| 245 | 256 | |
| 246 | | A08B-0033-B001 |
| 247 | | |--------------------------------------------| |
| 248 | | | ------------MAIN PCB---------------------- | |
| 249 | | | -----------SUB-PCB----------- | | |
| 250 | | | | | |
| 251 | | | |-----------------------| | | |
| 252 | | | | | | | |
| 253 | | | | | P | |
| 254 | | | | CRT UNIT | O | |
| 255 | | | | | W | |
| 256 | | | | | E | |
| 257 | | | | 12" COLOR | |---------| R | |
| 258 | | | | | |FDD UNIT | | | |
| 259 | | | | SCREEN | |A87L-0001| P | |
| 260 | | | | | |-0026 | C | |
| 261 | | | | | | | B | |
| 262 | | | | | | | | | |
| 263 | | | | | |5 1/4" | | | |
| 264 | | | | | |FLOPPY | | |
| 265 | | | | | |DRIVES | | |
| 266 | | | | | |x2 | | |
| 267 | | | |-----------------------| |---------| | |
| 268 | | |--------------------------------------------| |
| 257 | Box Layout (top view) |
| 258 | ---------- |
| 269 | 259 | |
| 260 | A08B-0033-B001 |
| 261 | |--------------------------------------------| |
| 262 | | ------------MAIN PCB---------------------- | |
| 263 | | -----------SUB-PCB----------- | | |
| 264 | | | | |
| 265 | | |-----------------------| | | |
| 266 | | | | | | |
| 267 | | | | P | |
| 268 | | | CRT UNIT | O | |
| 269 | | | | W | |
| 270 | | | | E | |
| 271 | | | 12" COLOR | |---------| R | |
| 272 | | | | |FDD UNIT | | | |
| 273 | | | SCREEN | |A87L-0001| P | |
| 274 | | | | |-0026 | C | |
| 275 | | | | | | B | |
| 276 | | | | | | | | |
| 277 | | | | |5 1/4" | | | |
| 278 | | | | |FLOPPY | | |
| 279 | | | | |DRIVES | | |
| 280 | | | | |x2 | | |
| 281 | | |-----------------------| |---------| | |
| 282 | |--------------------------------------------| |
| 270 | 283 | |
| 271 | | Main PCB Layout |
| 272 | | --------------- |
| 273 | 284 | |
| 274 | | A20B-1000-0710/03B |
| 275 | | |-------------------------------------------| |
| 276 | | | CNF CNE CND CNC CNB CNA | |
| 277 | | | VR1 ^ | |
| 278 | | | JUMPERS XXXXXXXXX| |
| 279 | | | % MB15541 XXXXXXXXXXXXXXXXXX| |
| 280 | | | XXXXXXXXXXXXXXXXXX| |
| 281 | | | 8087-3 D8253 XXXXXXXXXXXXXXXXXX| |
| 282 | | | 8086-2 D765 D8253 XXXXXXXXX| |
| 283 | | | D8257 | |
| 284 | | |15MHz D8259 D8259 D8251 D8251 | |
| 285 | | |D8284 040_001A.13A D8251 D8251 | |
| 286 | | | 040_002A.15A VR2 CN2 CN1 | |
| 287 | | | CN7 CN6 CN5 CN4 CN3 | |
| 288 | | |-------------------------------------------| |
| 289 | | Notes: |
| 290 | | D8086 - Intel 8086 CPU |
| 291 | | D8087 - Intel 8087 x87 Floating-Point Co-Processor |
| 292 | | XXXXXXX - Fujitsu MB8265-15 65536 x1-bit DRAM (72 chips total) |
| 293 | | MB15541 - Fujitsu MB15541 Custom Chip |
| 294 | | D765 - NEC D765 Single/Double Density Floppy-Disk Controller |
| 295 | | D8251 - Intel D8251 Programmable Communications Interface (USART) |
| 296 | | D8253 - NEC D8253 Programmable Interval Timer |
| 297 | | D8257 - NEC D8257 Programmable DMA Controller |
| 298 | | D8259 - NEC D8259 Programmable Interrupt Controller |
| 299 | | D8284 - Intel D8284 Clock Generator and Driver for 8086/8088 Processors |
| 300 | | A40_00* - Fujitsu MBM2764 8k x8-bit EPROM |
| 301 | | VR1/VR2 - Potentiometer |
| 302 | | ^ - 3 chips marked Y-E Data Fujitsu |
| 303 | | MB4393 |
| 304 | | MB14324 |
| 305 | | MB14323 |
| 306 | | % - Unknown 20-pin DIP chip with heat-sink |
| 307 | | CNA - 50-pin flat cable joining to Sub PCB |
| 308 | | CNB - 50-pin flat cable joining to Sub PCB |
| 309 | | CNC - 6-pin power cable joining to Sub PCB |
| 310 | | CND - 34-pin flat cable joining to FDD Unit |
| 311 | | CNE - Fanuc Honda MR-50 50-pin female connector for expansion (not used) |
| 312 | | CNF - Power input connector |
| 313 | | CN1 - 25-pin Female D-type connector. Generally this is connected to the CNC Machine serial port) |
| 314 | | CN2 - 25-pin Female D-type connector (for RS232 external peripherals) |
| 315 | | CN3 - 25-pin Female D-type connector (for RS232 external peripherals) |
| 316 | | CN4 - 25-pin Female D-type connector (for RS232 external peripherals) |
| 317 | | CN5 - Fanuc Honda MR-50 50-pin female connector (probably for external connection of the Fanuc Program File Unit) |
| 318 | | CN6 - Fanuc Honda MR-20 20-pin female connector for connection of the keyboard |
| 319 | | CN7 - Fanuc Honda MR-20 20-pin male Facit 4070 Parallel Reader/Puncher connector (PPR Unit) |
| 320 | | Pinout: (pin 1 is top left, location key is on the opposite side) |
| 321 | | |---------------------------------------------------| |
| 322 | | | | |
| 323 | | | 1_PR 2_TE 3_ERR 4_TTY3 5_+6V 6_TTY2 7_TTY1 | |
| 324 | | | | |
| 325 | | | 8_SG 9_SD 10_0V 11_CH1 12_CH2 13_CH3 O |
| 326 | | | | |
| 327 | | | 14_CH4 15_CH5 16_CH6 17_CH7 18_CH8 19_CH9 20_PI | |
| 328 | | | | |
| 329 | | |---------------------------------------------------| |
| 330 | | JUMPERS - 15 2-pin jumpers labelled S1 to S15. S2, S3 & S4 are not shorted. All others are shorted. |
| 285 | Main PCB Layout |
| 286 | --------------- |
| 331 | 287 | |
| 288 | A20B-1000-0710/03B |
| 289 | |-------------------------------------------| |
| 290 | | CNF CNE CND CNC CNB CNA | |
| 291 | | VR1 ^ | |
| 292 | | JUMPERS XXXXXXXXX| |
| 293 | | % MB15541 XXXXXXXXXXXXXXXXXX| |
| 294 | | XXXXXXXXXXXXXXXXXX| |
| 295 | | 8087-3 D8253 XXXXXXXXXXXXXXXXXX| |
| 296 | | 8086-2 D765 D8253 XXXXXXXXX| |
| 297 | | D8257 | |
| 298 | |15MHz D8259 D8259 D8251 D8251 | |
| 299 | |D8284 040_001A.13A D8251 D8251 | |
| 300 | | 040_002A.15A VR2 CN2 CN1 | |
| 301 | | CN7 CN6 CN5 CN4 CN3 | |
| 302 | |-------------------------------------------| |
| 303 | Notes: |
| 304 | D8086 - Intel 8086 CPU. Clock input 5.000MHz [15/3] |
| 305 | D8087 - Intel 8087 x87 Floating-Point Co-Processor. Clock input 5.000MHz [15/3] |
| 306 | XXXXXXX - Fujitsu MB8265-15 65536 x1-bit DRAM (72 chips total) |
| 307 | MB15541 - Fujitsu MB15541 Custom Chip |
| 308 | D765 - NEC D765 Single/Double Density Floppy-Disk Controller. Clock input 4.000MHz [16/4] |
| 309 | D8251 - Intel D8251 Programmable Communications Interface (USART) |
| 310 | D8253 - NEC D8253 Programmable Interval Timer. Clock input 1.25MHz [15/12] |
| 311 | D8257 - NEC D8257 Programmable DMA Controller. Clock input 3.000MHz [15/5] |
| 312 | D8259 - NEC D8259 Programmable Interrupt Controller |
| 313 | D8284 - Intel D8284 Clock Generator and Driver for 8086/8088 Processors |
| 314 | A40_00* - Fujitsu MBM2764 8k x8-bit EPROM |
| 315 | VR1/VR2 - Potentiometer |
| 316 | ^ - 3 chips marked Y-E Data Fujitsu |
| 317 | MB4393 |
| 318 | MB14324 |
| 319 | MB14323 |
| 320 | % - Unknown 20-pin Ceramic DIP chip with heat-sink |
| 321 | CNA - 50-pin flat cable joining to Sub PCB |
| 322 | CNB - 50-pin flat cable joining to Sub PCB |
| 323 | CNC - 6-pin power cable joining to Sub PCB |
| 324 | CND - 34-pin flat cable joining to FDD Unit |
| 325 | CNE - Fanuc Honda MR-50 50-pin female connector for expansion (not used) |
| 326 | CNF - Power input connector |
| 327 | CN1 - 25-pin Female D-type connector. (for RS232 external peripherals \ CNC Machine, |
| 328 | CN2 - 25-pin Female D-type connector. (for RS232 external peripherals | PPR Unit, X-Y Plotter, |
| 329 | CN3 - 25-pin Female D-type connector. (for RS232 external peripherals | Tablet, |
| 330 | CN4 - 25-pin Female D-type connector. (for RS232 external peripherals / Cassette Adapter etc (connections in any order) |
| 331 | CN5 - Fanuc Honda MR-50 50-pin female connector (probably for external connection of the Fanuc Program File Unit) |
| 332 | CN6 - Fanuc Honda MR-20 20-pin female connector for the keyboard |
| 333 | CN7 - Fanuc Honda MR-20 20-pin male. Specification says 'not used' but this appears to be a |
| 334 | Facit 4070 Parallel Reader/Puncher connector |
| 335 | Pinout: (pin 1 is top left, location key is on the opposite side) |
| 336 | |---------------------------------------------------| |
| 337 | | | |
| 338 | | 1_PR 2_TE 3_ERR 4_TTY3 5_+6V 6_TTY2 7_TTY1 | |
| 339 | | | |
| 340 | | 8_SG 9_SD 10_0V 11_CH1 12_CH2 13_CH3 O |
| 341 | | | |
| 342 | | 14_CH4 15_CH5 16_CH6 17_CH7 18_CH8 19_CH9 20_PI | |
| 343 | | | |
| 344 | |---------------------------------------------------| |
| 345 | JUMPERS - 15 2-pin jumpers labelled S1 to S15. S2, S3 & S4 are not shorted. All others are shorted. |
| 332 | 346 | |
| 333 | | Sub PCB Layout |
| 334 | | -------------- |
| 335 | 347 | |
| 336 | | A20B-1000-0720/02B |
| 337 | | |--------------------------------| |
| 338 | | | CNA CNB CNC CND | |
| 339 | | | | |
| 340 | | | MB15542 CNE| |
| 341 | | | | |
| 342 | | | HD6845S D8085| |
| 343 | | | 16MHz | |
| 344 | | | | |
| 345 | | | X | |
| 346 | | | XXXXXXXX | |
| 347 | | | XXXXXXXX | |
| 348 | | | XXXXXXXX 6264 A41_010B.28B| |
| 349 | | | 6264 A41_020A.30B| |
| 350 | | |--------------------------------| |
| 351 | | Notes: |
| 352 | | D8085 - NEC D8085A-2 CPU |
| 353 | | HD6845S - Hitachi HD6845S / HD46505S CRT Controller |
| 354 | | 6264 - Hitachi HM6264P-15 8k x 8-bit SRAM |
| 355 | | XXXXXXX - Fujitsu MB8265-15 65536 x1-bit DRAM (25 chips total) |
| 356 | | MB15542 - Fujitsu MB15542 Custom Chip |
| 357 | | A41_010B- Intel D27128 16k x8-bit EPROM |
| 358 | | A42_020A- Hitachi 27256G 32k x8-bit EPROM |
| 359 | | CNA - 50-pin flat cable joining to Main PCB |
| 360 | | CNB - 50-pin flat cable joining to Main PCB |
| 361 | | CNC - 6-pin power cable joining to Main PCB |
| 362 | | CND - 20-pin flat cable joining to CRT Unit (video output) |
| 363 | | CNE - Fanuc Honda MR-50 50-pin male connector for expansion (not used) |
| 348 | Sub PCB Layout |
| 349 | -------------- |
| 350 | |
| 351 | A20B-1000-0720/02B |
| 352 | |--------------------------------| |
| 353 | | CNA CNB CNC CND | |
| 354 | | | |
| 355 | | MB15542 CNE| |
| 356 | | | |
| 357 | | HD6845S D8085| |
| 358 | | 16MHz | |
| 359 | | | |
| 360 | | X | |
| 361 | | XXXXXXXX | |
| 362 | | XXXXXXXX | |
| 363 | | XXXXXXXX 6264 A41_010B.28B| |
| 364 | | 6264 A41_020A.30B| |
| 365 | |--------------------------------| |
| 366 | Notes: |
| 367 | D8085 - NEC D8085A-2 CPU. Clock input 8.000MHz [16/2]. |
| 368 | Note 8085 has internal /2 divider so actual clock speed is 4.000MHz |
| 369 | HD6845S - Hitachi HD6845S / HD46505S CRT Controller. Clock input 2.000MHz [8/2] |
| 370 | 6264 - Hitachi HM6264P-15 8k x 8-bit SRAM |
| 371 | XXXXXXX - Fujitsu MB8265-15 65536 x1-bit DRAM (25 chips total) |
| 372 | MB15542 - Fujitsu MB15542 Custom Chip |
| 373 | A41_010B- Intel D27128 16k x8-bit EPROM |
| 374 | A42_020A- Hitachi 27256G 32k x8-bit EPROM |
| 375 | CNA - 50-pin flat cable joining to Main PCB |
| 376 | CNB - 50-pin flat cable joining to Main PCB |
| 377 | CNC - 6-pin power cable joining to Main PCB |
| 378 | CND - 20-pin flat cable joining to CRT Unit (video output) |
| 379 | CNE - Fanuc Honda MR-50 50-pin male connector for expansion (not used) |
| 380 | HSync - 22.7273kHz |
| 381 | VSync - 54.6330Hz |
| 382 | |
| 383 | |
| 384 | Block Diagram |
| 385 | ------------- |
| 386 | Below is the block diagram shown in the Maintenance Manual. |
| 387 | The arrows denote direction of data flow. |
| 388 | |
| 389 | |-------| |--------| |----------------| |
| 390 | |Sub CPU| |Main CPU|<---->|Math Coprocessor| |
| 391 | |-------| |--------| |----------------| |
| 392 | /\ /\ /\ |
| 393 | | | | |
| 394 | | \/ \/ |
| 395 | |-----| | |------------------| |
| 396 | |EPROM|<--->| /\ |
| 397 | |-----| | |---------------| | |----------------| |
| 398 | | | Common memory |<---------------------------------->|<--->|RS232C interface|---CN1 |
| 399 | |<-------->|===============| | |----------------| |
| 400 | | /-->| Graphic memory|------| | |
| 401 | | | |---------------| | | |----------------| |
| 402 | | | | |--------| |<--->|RS232C interface|---CN2 |
| 403 | | | | | BOOT |<-------->| |----------------| |
| 404 | | | | | EPROM | | |
| 405 | | | |----------------| | |--------| | |----------------| |
| 406 | |<-----|-->|Character memory|--| | |<--->|RS232C interface|---CN3 |
| 407 | | |-->|----------------| | | |--------| | |----------------| |
| 408 | | | | | |Main RAM|<-------->| |
| 409 | | | | | |--------| | |----------------| |
| 410 | | | | | |<--->|RS232C interface|---CN4 |
| 411 | | | | | | |----------------| |
| 412 | |---------| | | \/ \/ | |
| 413 | |Keyboard | \/ \---|---------------------------| | |-----------------| CN9 |--------| |
| 414 | |interface|<->|<-------->| CRT control circuit | |<--->|Floppy controller|---O---|FDD UNIT| |
| 415 | |----|----| |-------------|-------------| | |-----------------| |--------| |
| 416 | | | | |
| 417 | | | \/ |
| 418 | O CN6 O CN8 O CN5 |
| 419 | | | |
| 420 | | | |
| 421 | |---|----| |----|----| |
| 422 | |Keyboard| | Screen | |
| 423 | |--------| |---------| |
| 364 | 424 | |
| 365 | 425 | |
| 366 | | Tech notes: |
| 367 | | - Once the big ASCII-art boot screen appears, you must press the "LOAD" key |
| 368 | | a few times to initiate booting from the floppy drive. |
| 369 | | |
| 370 | | |
| 371 | | The block diagram in the Maintenance Manual looks like this: |
| 372 | | |
| 373 | | |sub CPU| |main CPU|---|math coprocessor| |
| 374 | | | | | |
| 375 | | |EPROM|----| |---------------/ |
| 376 | | |-------------| Common memory / graphic memory | ------------------| |
| 377 | | | | |--------|RS232C interface|---CN1 |
| 378 | | | | |EPROM|-----|--------|RS232C interface|---CN2 |
| 379 | | |----|character memory| | |--------|RS232C interface|---CN3 |
| 380 | | | | | |main RAM|--|--------|RS232C interface|---CN4 |
| 381 | | | | | | |
| 382 | | |----| CRTC and video circuits |---CN8 | floppy controller |----CN9 |
| 383 | | | |
| 384 | | |keyboard interface|---CN6 |
| 385 | | |
| 386 | | |
| 387 | 426 | TODO: |
| 388 | | - Find char gen data. Is it inside the MB15542 custom? :-( |
| 389 | | - What's the a42_020a.30b ROM do? Both CPUs are currently happy without it, |
| 390 | | and it doesn't appear to contain valid 8086 or 8085 code. |
| 391 | 427 | - Is the VRAM hookup anything like correct? |
| 392 | 428 | - Hookup enough keyboard to get it to boot a floppy, the FAPT DOCTOR |
| 393 | 429 | program will be invaluable to answering many questions. |
| 394 | 430 | - Shared RAM is 8k, but there are 2 6264s on the sub board. Is shared RAM |
| 395 | 431 | banked? |
| 432 | - I/O is at F00xx: |
| 433 | ':maincpu' (FC15A): unmapped program memory write to F0012 = 00CE & 00FF |
| 434 | ':maincpu' (FC15D): unmapped program memory write to F0016 = 00CE & 00FF |
| 435 | ':maincpu' (FC160): unmapped program memory write to F001A = 00CE & 00FF |
| 436 | ':maincpu' (FC163): unmapped program memory write to F001E = 00CE & 00FF |
| 437 | ':maincpu' (FC16D): unmapped program memory write to F000E = 0034 & 00FF |
| 438 | ':maincpu' (FC172): unmapped program memory write to F0008 = 00D4 & 00FF |
| 439 | ':maincpu' (FC177): unmapped program memory write to F0008 = 0030 & 00FF |
| 440 | ':maincpu' (FC17C): unmapped program memory write to F000E = 0056 & 00FF |
| 441 | ':maincpu' (FC181): unmapped program memory write to F000A = 0010 & 00FF |
| 442 | ':maincpu' (FC186): unmapped program memory write to F000E = 0096 & 00FF |
| 443 | ':maincpu' (FC18B): unmapped program memory write to F000C = 0010 & 00FF |
| 444 | ':maincpu' (FC190): unmapped program memory write to F004E = 0034 & 00FF |
| 445 | ':maincpu' (FC195): unmapped program memory write to F0048 = 0020 & 00FF |
| 446 | ':maincpu' (FC19A): unmapped program memory write to F0048 = 004E & 00FF |
| 447 | ':maincpu' (FC19F): unmapped program memory write to F004E = 0056 & 00FF |
| 448 | ':maincpu' (FC1A4): unmapped program memory write to F004A = 0010 & 00FF |
| 449 | ':maincpu' (FC1A9): unmapped program memory write to F004E = 0096 & 00FF |
| 450 | ':maincpu' (FC1AE): unmapped program memory write to F004C = 0010 & 00FF |
| 396 | 451 | |
| 397 | 452 | ****************************************************************************/ |
| 398 | 453 | |
| r29424 | r29425 | |
| 481 | 536 | DECLARE_READ8_MEMBER(keyboard_r); |
| 482 | 537 | DECLARE_WRITE8_MEMBER(video_ctrl_w); |
| 483 | 538 | |
| 539 | DECLARE_READ8_MEMBER(test_r); |
| 540 | DECLARE_READ8_MEMBER(vbl_r); |
| 541 | |
| 484 | 542 | DECLARE_WRITE_LINE_MEMBER(vsync_w); |
| 485 | 543 | |
| 486 | 544 | DECLARE_DRIVER_INIT(fanucspmg); |
| r29424 | r29425 | |
| 493 | 551 | INT32 m_vram_bank; |
| 494 | 552 | UINT8 m_vbl_ctrl; |
| 495 | 553 | UINT8 m_keyboard_row; |
| 554 | UINT8 m_vbl_stat; |
| 496 | 555 | }; |
| 497 | 556 | |
| 498 | 557 | DRIVER_INIT_MEMBER(fanucspmg_state, fanucspmg) |
| r29424 | r29425 | |
| 516 | 575 | m_shared[offset] = data; |
| 517 | 576 | } |
| 518 | 577 | |
| 578 | READ8_MEMBER(fanucspmg_state::test_r) |
| 579 | { |
| 580 | return 0x00; // 0x80 to start weird not-sure-what process which may be FDC related |
| 581 | } |
| 582 | |
| 583 | READ8_MEMBER(fanucspmg_state::vbl_r) |
| 584 | { |
| 585 | return m_vbl_stat; |
| 586 | } |
| 587 | |
| 519 | 588 | static ADDRESS_MAP_START(maincpu_mem, AS_PROGRAM, 16, fanucspmg_state) |
| 520 | 589 | AM_RANGE(0x00000, 0x7ffff) AM_RAM // main RAM |
| 521 | 590 | |
| 522 | | AM_RANGE(0xf0000, 0xf00ff) AM_RAM // not sure if this is RAM or I/O |
| 591 | AM_RANGE(0x88000, 0x88001) AM_READ8(vbl_r, 0xffff) |
| 523 | 592 | |
| 593 | AM_RANGE(0xf0004, 0xf0005) AM_READ8(test_r, 0xffff) |
| 594 | |
| 524 | 595 | AM_RANGE(0xf8000, 0xf9fff) AM_READWRITE8(shared_r, shared_w, 0xffff) |
| 525 | | |
| 526 | 596 | AM_RANGE(0xfc000, 0xfffff) AM_ROM AM_REGION(MAINCPU_TAG, 0) |
| 527 | 597 | ADDRESS_MAP_END |
| 528 | 598 | |
| r29424 | r29425 | |
| 538 | 608 | m_subcpu->set_input_line(I8085_RST75_LINE, ASSERT_LINE); |
| 539 | 609 | } |
| 540 | 610 | } |
| 611 | |
| 612 | m_vbl_stat = (state == ASSERT_LINE) ? 1 : 0; |
| 541 | 613 | } |
| 542 | 614 | |
| 543 | 615 | READ8_MEMBER(fanucspmg_state::vram1_r) |
| r29424 | r29425 | |
| 572 | 644 | return 0xff; |
| 573 | 645 | } |
| 574 | 646 | |
| 647 | // bit 1 seems to route to bit 7 of f0004 on the 8086 (signals the "LOAD" key pressed?) |
| 575 | 648 | // bit 3 appears to enable vblank IRQs |
| 576 | 649 | WRITE8_MEMBER(fanucspmg_state::vbl_ctrl_w) |
| 577 | 650 | { |
| r29424 | r29425 | |
| 725 | 798 | |
| 726 | 799 | static MACHINE_CONFIG_START( fanucspmg, fanucspmg_state ) |
| 727 | 800 | /* basic machine hardware */ |
| 728 | | MCFG_CPU_ADD(MAINCPU_TAG, I8086, XTAL_15MHz/4) // guess - 3.75 MHz |
| 801 | MCFG_CPU_ADD(MAINCPU_TAG, I8086, XTAL_15MHz/3) |
| 729 | 802 | MCFG_CPU_PROGRAM_MAP(maincpu_mem) |
| 730 | 803 | MCFG_CPU_IO_MAP(maincpu_io) |
| 731 | 804 | |
| 732 | | MCFG_CPU_ADD(SUBCPU_TAG, I8085A, XTAL_16MHz/8) // part is -2 rated |
| 805 | MCFG_CPU_ADD(SUBCPU_TAG, I8085A, XTAL_16MHz/2/2) |
| 733 | 806 | MCFG_CPU_PROGRAM_MAP(subcpu_mem) |
| 734 | 807 | |
| 735 | 808 | MCFG_DEVICE_ADD(USART0_TAG, I8251, 0) |
| r29424 | r29425 | |
| 738 | 811 | MCFG_DEVICE_ADD(USART3_TAG, I8251, 0) |
| 739 | 812 | |
| 740 | 813 | MCFG_DEVICE_ADD(PIT0_TAG, PIT8253, 0) |
| 741 | | MCFG_PIT8253_CLK0(XTAL_15MHz/4) |
| 742 | | MCFG_PIT8253_CLK1(XTAL_15MHz/4) |
| 743 | | MCFG_PIT8253_CLK2(XTAL_15MHz/4) |
| 814 | MCFG_PIT8253_CLK0(XTAL_15MHz/12) |
| 815 | MCFG_PIT8253_CLK1(XTAL_15MHz/12) |
| 816 | MCFG_PIT8253_CLK2(XTAL_15MHz/12) |
| 744 | 817 | MCFG_DEVICE_ADD(PIT1_TAG, PIT8253, 0) |
| 745 | | MCFG_PIT8253_CLK0(XTAL_15MHz/4) |
| 746 | | MCFG_PIT8253_CLK1(XTAL_15MHz/4) |
| 747 | | MCFG_PIT8253_CLK2(XTAL_15MHz/4) |
| 818 | MCFG_PIT8253_CLK0(XTAL_15MHz/12) |
| 819 | MCFG_PIT8253_CLK1(XTAL_15MHz/12) |
| 820 | MCFG_PIT8253_CLK2(XTAL_15MHz/12) |
| 748 | 821 | |
| 749 | | MCFG_I8257_ADD(DMAC_TAG, XTAL_15MHz / 4, fanucspmg_dma) |
| 822 | MCFG_I8257_ADD(DMAC_TAG, XTAL_15MHz / 5, fanucspmg_dma) |
| 750 | 823 | |
| 751 | 824 | MCFG_PIC8259_ADD(PIC0_TAG, INPUTLINE("maincpu", 0), VCC, NULL) |
| 752 | 825 | MCFG_PIC8259_ADD(PIC1_TAG, INPUTLINE("maincpu", 0), VCC, NULL) |
| r29424 | r29425 | |
| 759 | 832 | MCFG_SCREEN_RAW_PARAMS(XTAL_15MHz, 640, 0, 512, 390, 0, 384 ) |
| 760 | 833 | MCFG_SCREEN_UPDATE_DEVICE( CRTC_TAG, mc6845_device, screen_update ) |
| 761 | 834 | |
| 762 | | MCFG_MC6845_ADD( CRTC_TAG, HD6845, SCREEN_TAG, XTAL_15MHz/3, mc6845_fanuc_intf) |
| 835 | MCFG_MC6845_ADD( CRTC_TAG, HD6845, SCREEN_TAG, XTAL_8MHz/2, mc6845_fanuc_intf) |
| 763 | 836 | MACHINE_CONFIG_END |
| 764 | 837 | |
| 765 | 838 | /* ROM definition */ |
branches/new_menus/src/mess/drivers/a7800.c
| r29424 | r29425 | |
| 75 | 75 | 2014/01/02 Robert Tuccitto Corrected joystick buttons assignment & minor |
| 76 | 76 | palette notes cleanup. |
| 77 | 77 | |
| 78 | | 2014/01/09 Robert Tuccitto Positional description for difficulty |
| 79 | | switches added. |
| 78 | 2014/01/09 Robert Tuccitto Positional description for difficulty |
| 79 | switches added. |
| 80 | 80 | |
| 81 | | 2014/02/15 Robert Tuccitto Added more details and clarification |
| 82 | | regarding the potentiometer. |
| 81 | 2014/02/15 Robert Tuccitto Added more details and clarification |
| 82 | regarding the potentiometer. |
| 83 | 83 | |
| 84 | | 2014/03/25 Mike Saarna Fixed Riot Timer |
| 84 | 2014/03/25 Mike Saarna Fixed Riot Timer |
| 85 | 85 | ***************************************************************************/ |
| 86 | 86 | |
| 87 | 87 | #include "emu.h" |
| r29424 | r29425 | |
| 259 | 259 | structure order and have similar appearance differences that are dependent |
| 260 | 260 | upon display type. |
| 261 | 261 | ***************************************************************************/ |
| 262 | |
| 262 | 263 | /*************************************************************************** |
| 263 | | PALETTE - 26.2 PHASE SHIFT |
| 264 | PALETTE - 25.7 PHASE SHIFT |
| 264 | 265 | ***************************************************************************/ |
| 265 | 266 | |
| 266 | 267 | #define NTSC_GREY \ |
| 267 | | rgb_t(0x00,0x00,0x00), rgb_t(0x11,0x11,0x11), rgb_t(0x22,0x22,0x22), rgb_t(0x33,0x33,0x33), \ |
| 268 | | rgb_t(0x44,0x44,0x44), rgb_t(0x55,0x55,0x55), rgb_t(0x66,0x66,0x66), rgb_t(0x77,0x77,0x77), \ |
| 269 | | rgb_t(0x88,0x88,0x88), rgb_t(0x99,0x99,0x99), rgb_t(0xAA,0xAA,0xAA), rgb_t(0xBB,0xBB,0xBB), \ |
| 270 | | rgb_t(0xCC,0xCC,0xCC), rgb_t(0xDD,0xDD,0xDD), rgb_t(0xEE,0xEE,0xEE), rgb_t(0xFF,0xFF,0xFF ) |
| 268 | rgb_t(0x00,0x00,0x00), rgb_t(0x11,0x11,0x11), rgb_t(0x22,0x22,0x22), rgb_t(0x33,0x33,0x33), \ |
| 269 | rgb_t(0x44,0x44,0x44), rgb_t(0x55,0x55,0x55), rgb_t(0x66,0x66,0x66), rgb_t(0x77,0x77,0x77), \ |
| 270 | rgb_t(0x88,0x88,0x88), rgb_t(0x99,0x99,0x99), rgb_t(0xAA,0xAA,0xAA), rgb_t(0xBB,0xBB,0xBB), \ |
| 271 | rgb_t(0xCC,0xCC,0xCC), rgb_t(0xDD,0xDD,0xDD), rgb_t(0xEE,0xEE,0xEE), rgb_t(0xFF,0xFF,0xFF ) |
| 271 | 272 | |
| 272 | 273 | #define NTSC_GOLD \ |
| 273 | | rgb_t(0x1A,0x07,0x00), rgb_t(0x2B,0x18,0x00), rgb_t(0x3C,0x29,0x00), rgb_t(0x4D,0x3A,0x00), \ |
| 274 | | rgb_t(0x5E,0x4B,0x00), rgb_t(0x6F,0x5C,0x00), rgb_t(0x80,0x6D,0x00), rgb_t(0x91,0x7E,0x09), \ |
| 275 | | rgb_t(0xA2,0x8F,0x1A), rgb_t(0xB3,0xA0,0x2B), rgb_t(0xC4,0xB1,0x3C), rgb_t(0xD5,0xC2,0x4D), \ |
| 276 | | rgb_t(0xE6,0xD3,0x5E), rgb_t(0xF7,0xE4,0x6F), rgb_t(0xFF,0xF5,0x83), rgb_t(0xFF,0xF7,0x97 ) |
| 274 | rgb_t(0x1A,0x07,0x00), rgb_t(0x2B,0x18,0x00), rgb_t(0x3C,0x29,0x00), rgb_t(0x4D,0x3A,0x00), \ |
| 275 | rgb_t(0x5E,0x4B,0x00), rgb_t(0x6F,0x5C,0x00), rgb_t(0x80,0x6D,0x00), rgb_t(0x91,0x7E,0x09), \ |
| 276 | rgb_t(0xA2,0x8F,0x1A), rgb_t(0xB3,0xA0,0x2B), rgb_t(0xC4,0xB1,0x3C), rgb_t(0xD5,0xC2,0x4D), \ |
| 277 | rgb_t(0xE6,0xD3,0x5E), rgb_t(0xF7,0xE4,0x6F), rgb_t(0xFF,0xF5,0x83), rgb_t(0xFF,0xF7,0x97 ) |
| 277 | 278 | |
| 278 | 279 | #define NTSC_ORANGE \ |
| 279 | | rgb_t(0x31,0x00,0x00), rgb_t(0x42,0x06,0x00), rgb_t(0x53,0x17,0x00), rgb_t(0x64,0x28,0x00), \ |
| 280 | | rgb_t(0x75,0x39,0x00), rgb_t(0x86,0X4A,0x00), rgb_t(0x97,0x5B,0x0B), rgb_t(0xA8,0x6C,0x1C), \ |
| 281 | | rgb_t(0xB9,0x7D,0x2D), rgb_t(0xCA,0x8E,0x3E), rgb_t(0xDB,0x9F,0x4F), rgb_t(0xEC,0xB0,0x60), \ |
| 282 | | rgb_t(0xFD,0xC1,0x71), rgb_t(0xFF,0xD2,0x86), rgb_t(0xFF,0xE3,0x9D), rgb_t(0xFF,0xF4,0xB3 ) |
| 280 | rgb_t(0x31,0x00,0x00), rgb_t(0x42,0x06,0x00), rgb_t(0x53,0x17,0x00), rgb_t(0x64,0x28,0x00), \ |
| 281 | rgb_t(0x75,0x39,0x00), rgb_t(0x86,0X4A,0x00), rgb_t(0x97,0x5B,0x0A), rgb_t(0xA8,0x6C,0x1B), \ |
| 282 | rgb_t(0xB9,0x7D,0x2C), rgb_t(0xCA,0x8E,0x3D), rgb_t(0xDB,0x9F,0x4E), rgb_t(0xEC,0xB0,0x5F), \ |
| 283 | rgb_t(0xFD,0xC1,0x70), rgb_t(0xFF,0xD2,0x85), rgb_t(0xFF,0xE3,0x9C), rgb_t(0xFF,0xF4,0xB2 ) |
| 283 | 284 | |
| 284 | 285 | #define NTSC_RED_ORANGE \ |
| 285 | | rgb_t(0x3E,0x00,0x00), rgb_t(0x4F,0x00,0x00), rgb_t(0x60,0x08,0x00), rgb_t(0x71,0x19,0x00), \ |
| 286 | | rgb_t(0x82,0x2A,0x0F), rgb_t(0x93,0x3B,0x20), rgb_t(0xA4,0x4C,0x31), rgb_t(0xB5,0x5D,0x42), \ |
| 287 | | rgb_t(0xC6,0x6E,0x53), rgb_t(0xD7,0x7F,0x64), rgb_t(0xE8,0x90,0x75), rgb_t(0xF9,0xA1,0x86), \ |
| 288 | | rgb_t(0xFF,0xB2,0x9A), rgb_t(0xFF,0xC3,0xB0), rgb_t(0xFF,0xD4,0xC6), rgb_t(0xFF,0xE5,0xDC ) |
| 286 | rgb_t(0x3E,0x00,0x00), rgb_t(0x4F,0x00,0x00), rgb_t(0x60,0x08,0x00), rgb_t(0x71,0x19,0x00), \ |
| 287 | rgb_t(0x82,0x2A,0x0D), rgb_t(0x93,0x3B,0x1E), rgb_t(0xA4,0x4C,0x2F), rgb_t(0xB5,0x5D,0x40), \ |
| 288 | rgb_t(0xC6,0x6E,0x51), rgb_t(0xD7,0x7F,0x62), rgb_t(0xE8,0x90,0x73), rgb_t(0xF9,0xA1,0x83), \ |
| 289 | rgb_t(0xFF,0xB2,0x98), rgb_t(0xFF,0xC3,0xAE), rgb_t(0xFF,0xD4,0xC4), rgb_t(0xFF,0xE5,0xDA ) |
| 289 | 290 | |
| 290 | 291 | #define NTSC_PINK \ |
| 291 | | rgb_t(0x3E,0x00,0x06), rgb_t(0x4F,0x00,0x12), rgb_t(0x60,0x00,0x1E), rgb_t(0x71,0x0E,0x2E), \ |
| 292 | | rgb_t(0x82,0x1F,0x3F), rgb_t(0x93,0x30,0x50), rgb_t(0xA4,0x41,0x61), rgb_t(0xB5,0x52,0x72), \ |
| 293 | | rgb_t(0xC6,0x63,0x83), rgb_t(0xD7,0x74,0x94), rgb_t(0xE8,0x85,0xA5), rgb_t(0xF9,0x96,0xB6), \ |
| 294 | | rgb_t(0xFF,0xA7,0xCB), rgb_t(0xFF,0xB8,0xE1), rgb_t(0xFF,0xC9,0xEF), rgb_t(0xFF,0xDA,0xF4 ) |
| 292 | rgb_t(0x3F,0x00,0x03), rgb_t(0x50,0x00,0x0F), rgb_t(0x61,0x00,0x1B), rgb_t(0x72,0x0F,0x2B), \ |
| 293 | rgb_t(0x83,0x20,0x3C), rgb_t(0x94,0x31,0x4D), rgb_t(0xA5,0x42,0x5E), rgb_t(0xB6,0x53,0x6F), \ |
| 294 | rgb_t(0xC7,0x64,0x80), rgb_t(0xD8,0x75,0x91), rgb_t(0xE9,0x86,0xA2), rgb_t(0xFA,0x97,0xB3), \ |
| 295 | rgb_t(0xFF,0xA8,0xC8), rgb_t(0xFF,0xB9,0xDE), rgb_t(0xFF,0xCA,0xEF), rgb_t(0xFF,0xDB,0xF4 ) |
| 295 | 296 | |
| 296 | 297 | #define NTSC_PURPLE \ |
| 297 | | rgb_t(0x32,0x00,0x38), rgb_t(0x43,0x00,0x44), rgb_t(0x54,0x00,0x50), rgb_t(0x65,0x0C,0x5F), \ |
| 298 | | rgb_t(0x76,0x1D,0x70), rgb_t(0x87,0x2E,0x81), rgb_t(0x98,0x3F,0x92), rgb_t(0xA9,0x50,0xA3), \ |
| 299 | | rgb_t(0xBA,0x61,0xB4), rgb_t(0xCB,0x72,0xC5), rgb_t(0xDC,0x83,0xD6), rgb_t(0xED,0x94,0xE4), \ |
| 300 | | rgb_t(0xFE,0xA5,0xE4), rgb_t(0xFF,0xB6,0xE9), rgb_t(0xFF,0xC7,0xEE), rgb_t(0xFF,0xD8,0xF3 ) |
| 298 | rgb_t(0x33,0x00,0x35), rgb_t(0x44,0x00,0x41), rgb_t(0x55,0x00,0x4C), rgb_t(0x66,0x0C,0x5C), \ |
| 299 | rgb_t(0x77,0x1D,0x6D), rgb_t(0x88,0x2E,0x7E), rgb_t(0x99,0x3F,0x8F), rgb_t(0xAA,0x50,0xA0), \ |
| 300 | rgb_t(0xBB,0x61,0xB1), rgb_t(0xCC,0x72,0xC2), rgb_t(0xDD,0x83,0xD3), rgb_t(0xEE,0x94,0xE4), \ |
| 301 | rgb_t(0xFF,0xA5,0xE4), rgb_t(0xFF,0xB6,0xE9), rgb_t(0xFF,0xC7,0xEE), rgb_t(0xFF,0xD8,0xF3 ) |
| 301 | 302 | |
| 302 | 303 | #define NTSC_PURPLE_BLUE \ |
| 303 | | rgb_t(0x1B,0x00,0x5F), rgb_t(0x2C,0x00,0x6B), rgb_t(0x3D,0x00,0x77), rgb_t(0x4E,0x11,0x88), \ |
| 304 | | rgb_t(0x5F,0x22,0x99), rgb_t(0x70,0x33,0xAA), rgb_t(0x81,0x44,0xBB), rgb_t(0x92,0x55,0xCC), \ |
| 305 | | rgb_t(0xA3,0x66,0xDD), rgb_t(0xB4,0x77,0xED), rgb_t(0xC5,0x88,0xED), rgb_t(0xD6,0x99,0xED), \ |
| 306 | | rgb_t(0xE7,0xAA,0xED), rgb_t(0xF8,0xBB,0xED), rgb_t(0xFF,0xCC,0xF0), rgb_t(0xFF,0xDD,0xF5 ) |
| 304 | rgb_t(0x1D,0x00,0x5C), rgb_t(0x2E,0x00,0x68), rgb_t(0x40,0x00,0x74), rgb_t(0x51,0x10,0x84), \ |
| 305 | rgb_t(0x62,0x21,0x95), rgb_t(0x73,0x32,0xA6), rgb_t(0x84,0x43,0xB7), rgb_t(0x95,0x54,0xC8), \ |
| 306 | rgb_t(0xA6,0x65,0xD9), rgb_t(0xB7,0x76,0xEA), rgb_t(0xC8,0x87,0xEB), rgb_t(0xD9,0x98,0xEB), \ |
| 307 | rgb_t(0xE9,0xA9,0xEC), rgb_t(0xFB,0xBA,0xEB), rgb_t(0xFF,0xCB,0xEF), rgb_t(0xFF,0xDC,0xF4 ) |
| 307 | 308 | |
| 308 | 309 | #define NTSC_BLUE1 \ |
| 309 | | rgb_t(0x00,0x00,0x72), rgb_t(0x10,0x00,0x7E), rgb_t(0x21,0x0D,0x8E), rgb_t(0x32,0x1E,0x9F), \ |
| 310 | | rgb_t(0x43,0x2F,0xB0), rgb_t(0x54,0x40,0xC1), rgb_t(0x65,0x51,0xD2), rgb_t(0x76,0x62,0xE3), \ |
| 311 | | rgb_t(0x87,0x73,0xF4), rgb_t(0x98,0x84,0xF9), rgb_t(0xA9,0x95,0xF9), rgb_t(0xBA,0xA6,0xF9), \ |
| 312 | | rgb_t(0xCB,0xB7,0xF9), rgb_t(0xDC,0xC8,0xF9), rgb_t(0xED,0xD9,0xF9), rgb_t(0xFE,0xEA,0xF9 ) |
| 310 | rgb_t(0x02,0x00,0x71), rgb_t(0x13,0x00,0x7D), rgb_t(0x24,0x0B,0x8C), rgb_t(0x35,0x1C,0x9D), \ |
| 311 | rgb_t(0x46,0x2D,0xAE), rgb_t(0x57,0x3E,0xBF), rgb_t(0x68,0x4F,0xD0), rgb_t(0x79,0x60,0xE1), \ |
| 312 | rgb_t(0x8A,0x71,0xF2), rgb_t(0x9B,0x82,0xF7), rgb_t(0xAC,0x93,0xF7), rgb_t(0xBD,0xA4,0xF7), \ |
| 313 | rgb_t(0xCE,0xB5,0xF7), rgb_t(0xDF,0xC6,0xF7), rgb_t(0xF0,0xD7,0xF7), rgb_t(0xFF,0xE8,0xF8 ) |
| 313 | 314 | |
| 314 | 315 | #define NTSC_BLUE2 \ |
| 315 | | rgb_t(0x00,0x00,0x65), rgb_t(0x00,0x0C,0x7A), rgb_t(0x05,0x1D,0x8E), rgb_t(0x16,0x2E,0x9F), \ |
| 316 | | rgb_t(0x27,0x3F,0xB0), rgb_t(0x38,0x50,0xC1), rgb_t(0x49,0x61,0xD2), rgb_t(0x5A,0x72,0xE3), \ |
| 317 | | rgb_t(0x6B,0x83,0xF4), rgb_t(0x7C,0x94,0xFF), rgb_t(0x8D,0xA5,0xFF), rgb_t(0x9E,0xB6,0xFF), \ |
| 318 | | rgb_t(0xAF,0xC7,0xFF), rgb_t(0xC0,0xD8,0xFF), rgb_t(0xD1,0xE9,0xFF), rgb_t(0xE2,0xFA,0xFF ) |
| 316 | rgb_t(0x00,0x00,0x68), rgb_t(0x00,0x0A,0x7C), rgb_t(0x08,0x1B,0x90), rgb_t(0x19,0x2C,0xA1), \ |
| 317 | rgb_t(0x2A,0x3D,0xB2), rgb_t(0x3B,0x4E,0xC3), rgb_t(0x4C,0x5F,0xD4), rgb_t(0x5D,0x70,0xE5), \ |
| 318 | rgb_t(0x6E,0x81,0xF6), rgb_t(0x7F,0x92,0xFF), rgb_t(0x90,0xA3,0xFF), rgb_t(0xA1,0xB4,0xFF), \ |
| 319 | rgb_t(0xB2,0xC5,0xFF), rgb_t(0xC3,0xD6,0xFF), rgb_t(0xD4,0xE7,0xFF), rgb_t(0xE5,0xF8,0xFF ) |
| 319 | 320 | |
| 320 | 321 | #define NTSC_LIGHT_BLUE \ |
| 321 | | rgb_t(0x00,0x0D,0x48), rgb_t(0x00,0x1E,0x5E), rgb_t(0x00,0x2F,0x74), rgb_t(0x00,0x40,0x8A), \ |
| 322 | | rgb_t(0x11,0x51,0x9B), rgb_t(0x22,0x62,0xAC), rgb_t(0x33,0x73,0xBD), rgb_t(0x44,0x84,0xCE), \ |
| 323 | | rgb_t(0x55,0x95,0xDF), rgb_t(0x66,0xA6,0xF0), rgb_t(0x77,0xB7,0xFF), rgb_t(0x88,0xC8,0xFF), \ |
| 324 | | rgb_t(0x99,0xD9,0xFF), rgb_t(0xAA,0xEA,0xFF), rgb_t(0xBB,0xFB,0xFF), rgb_t(0xCC,0xFF,0xFF ) |
| 322 | rgb_t(0x00,0x0A,0x4D), rgb_t(0x00,0x1B,0x63), rgb_t(0x00,0x2C,0x79), rgb_t(0x02,0x3D,0x8F), \ |
| 323 | rgb_t(0x13,0x4E,0xA0), rgb_t(0x24,0x5F,0xB1), rgb_t(0x35,0x70,0xC2), rgb_t(0x46,0x81,0xD3), \ |
| 324 | rgb_t(0x57,0x92,0xE4), rgb_t(0x68,0xA3,0xF5), rgb_t(0x79,0xB4,0xFF), rgb_t(0x8A,0xC5,0xFF), \ |
| 325 | rgb_t(0x9B,0xD6,0xFF), rgb_t(0xAC,0xE7,0xFF), rgb_t(0xBD,0xF8,0xFF), rgb_t(0xCE,0xFF,0xFF ) |
| 325 | 326 | |
| 326 | 327 | #define NTSC_TURQUOISE \ |
| 327 | | rgb_t(0x00,0x1C,0x1C), rgb_t(0x00,0x2D,0x32), rgb_t(0x00,0x3E,0x49), rgb_t(0x00,0x4F,0x5F), \ |
| 328 | | rgb_t(0x05,0x60,0x73), rgb_t(0x16,0x71,0x84), rgb_t(0x27,0x82,0x95), rgb_t(0x38,0x93,0xA6), \ |
| 329 | | rgb_t(0x49,0xA4,0xB7), rgb_t(0x5A,0xB5,0xC8), rgb_t(0x6B,0xC6,0xD9), rgb_t(0x7C,0xD7,0xEA), \ |
| 330 | | rgb_t(0x8D,0xE8,0xFB), rgb_t(0x9E,0xF9,0xFF), rgb_t(0xAF,0xFF,0xFF), rgb_t(0xC0,0xFF,0xFF ) |
| 328 | rgb_t(0x00,0x1A,0x26), rgb_t(0x00,0x2B,0x3C), rgb_t(0x00,0x3C,0x52), rgb_t(0x00,0x4D,0x68), \ |
| 329 | rgb_t(0x06,0x5E,0x7C), rgb_t(0x17,0x6F,0x8D), rgb_t(0x28,0x80,0x9E), rgb_t(0x39,0x91,0xAF), \ |
| 330 | rgb_t(0x4A,0xA2,0xC0), rgb_t(0x5B,0xB3,0xD1), rgb_t(0x6C,0xC4,0xE2), rgb_t(0x7D,0xD5,0xF3), \ |
| 331 | rgb_t(0x8E,0xE6,0xFF), rgb_t(0x9F,0xF7,0xFF), rgb_t(0xB0,0xFF,0xFF), rgb_t(0xC1,0xFF,0xFF ) |
| 331 | 332 | |
| 332 | 333 | #define NTSC_GREEN_BLUE \ |
| 333 | | rgb_t(0x00,0x25,0x0B), rgb_t(0x00,0x36,0x10), rgb_t(0x00,0x47,0x18), rgb_t(0x00,0x58,0x2E), \ |
| 334 | | rgb_t(0x07,0x69,0x42), rgb_t(0x18,0x7A,0x53), rgb_t(0x29,0x8B,0x64), rgb_t(0x3A,0x9C,0x75), \ |
| 335 | | rgb_t(0x4B,0xAD,0x86), rgb_t(0x5C,0xBE,0x97), rgb_t(0x6D,0xCF,0xA8), rgb_t(0x7E,0xE0,0xB9), \ |
| 336 | | rgb_t(0x8F,0xF1,0xCA), rgb_t(0xA0,0xFF,0xDA), rgb_t(0xB1,0xFF,0xE6), rgb_t(0xC2,0xFF,0xF2 ) |
| 334 | rgb_t(0x00,0x24,0x0B), rgb_t(0x00,0x35,0x10), rgb_t(0x00,0x46,0x22), rgb_t(0x00,0x57,0x38), \ |
| 335 | rgb_t(0x05,0x68,0x4D), rgb_t(0x16,0x79,0x5E), rgb_t(0x27,0x8A,0x6F), rgb_t(0x38,0x9B,0x80), \ |
| 336 | rgb_t(0x49,0xAC,0x91), rgb_t(0x5A,0xBD,0xA2), rgb_t(0x6B,0xCE,0xB3), rgb_t(0x7C,0xDF,0xC4), \ |
| 337 | rgb_t(0x8D,0xF0,0xD5), rgb_t(0x9E,0xFF,0xE5), rgb_t(0xAF,0xFF,0xF1), rgb_t(0xC0,0xFF,0xFD ) |
| 337 | 338 | |
| 338 | 339 | #define NTSC_GREEN \ |
| 339 | | rgb_t(0x00,0x27,0x0C), rgb_t(0x00,0x38,0x11), rgb_t(0x00,0x49,0x16), rgb_t(0x04,0x5A,0x1A), \ |
| 340 | | rgb_t(0x15,0x6B,0x1A), rgb_t(0x26,0x7C,0x22), rgb_t(0x37,0x8D,0x33), rgb_t(0x48,0x9E,0x44), \ |
| 341 | | rgb_t(0x59,0xAF,0x55), rgb_t(0x6A,0xC0,0x66), rgb_t(0x7B,0xD1,0x77), rgb_t(0x8C,0xE2,0x88), \ |
| 342 | | rgb_t(0x9D,0xF3,0x99), rgb_t(0xAE,0xFF,0xA8), rgb_t(0xBF,0xFF,0xB4), rgb_t(0xD0,0xFF,0xC0 ) |
| 340 | rgb_t(0x00,0x27,0x0C), rgb_t(0x00,0x38,0x11), rgb_t(0x00,0x49,0x16), rgb_t(0x00,0x5A,0x1B), \ |
| 341 | rgb_t(0x10,0x6B,0x1B), rgb_t(0x21,0x7C,0x2C), rgb_t(0x32,0x8D,0x3D), rgb_t(0x43,0x9E,0x4E), \ |
| 342 | rgb_t(0x54,0xAF,0x5F), rgb_t(0x65,0xC0,0x70), rgb_t(0x76,0xD1,0x81), rgb_t(0x87,0xE2,0x92), \ |
| 343 | rgb_t(0x98,0xF3,0xA3), rgb_t(0xA9,0xFF,0xB3), rgb_t(0xBA,0xFF,0xBF), rgb_t(0xCB,0xFF,0xCB ) |
| 343 | 344 | |
| 344 | 345 | #define NTSC_YELLOW_GREEN \ |
| 345 | | rgb_t(0x00,0x21,0x0A), rgb_t(0x00,0x32,0x0F), rgb_t(0x0A,0x43,0x11), rgb_t(0x1B,0x54,0x11), \ |
| 346 | | rgb_t(0x2C,0x65,0x11), rgb_t(0x3D,0x76,0x11), rgb_t(0x4E,0x87,0x11), rgb_t(0x5F,0x98,0x1E), \ |
| 347 | | rgb_t(0x70,0xA9,0x2F), rgb_t(0x81,0xBA,0x40), rgb_t(0x92,0xCB,0x51), rgb_t(0xA3,0xDC,0x62), \ |
| 348 | | rgb_t(0xB4,0xED,0x73), rgb_t(0xC5,0xFE,0x84), rgb_t(0xD6,0xFF,0x90), rgb_t(0xE7,0xFF,0x9C ) |
| 346 | rgb_t(0x00,0x23,0x0A), rgb_t(0x00,0x34,0x10), rgb_t(0x04,0x45,0x13), rgb_t(0x15,0x56,0x13), \ |
| 347 | rgb_t(0x26,0x67,0x13), rgb_t(0x37,0x78,0x13), rgb_t(0x48,0x89,0x14), rgb_t(0x59,0x9A,0x25), \ |
| 348 | rgb_t(0x6A,0xAB,0x36), rgb_t(0x7B,0xBC,0x47), rgb_t(0x8C,0xCD,0x58), rgb_t(0x9D,0xDE,0x69), \ |
| 349 | rgb_t(0xAE,0xEF,0x7A), rgb_t(0xBF,0xFF,0x8B), rgb_t(0xD0,0xFF,0x97), rgb_t(0xE1,0xFF,0xA3 ) |
| 349 | 350 | |
| 350 | 351 | #define NTSC_ORANGE_GREEN \ |
| 351 | | rgb_t(0x05,0x13,0x04), rgb_t(0x16,0x24,0x04), rgb_t(0x27,0x35,0x04), rgb_t(0x38,0x46,0x04), \ |
| 352 | | rgb_t(0x49,0x57,0x04), rgb_t(0x5A,0x68,0x04), rgb_t(0x6B,0x79,0x04), rgb_t(0x7C,0x8A,0x09), \ |
| 353 | | rgb_t(0x8D,0x9B,0x1A), rgb_t(0x9E,0xAC,0x2B), rgb_t(0xAF,0xBD,0x3C), rgb_t(0xC0,0xCE,0x4D), \ |
| 354 | | rgb_t(0xD1,0xDF,0x5E), rgb_t(0xE2,0xF0,0x6F), rgb_t(0xF3,0xFF,0x80), rgb_t(0xFF,0xFF,0x8D ) |
| 352 | rgb_t(0x00,0x17,0x07), rgb_t(0x0E,0x28,0x08), rgb_t(0x1F,0x39,0x08), rgb_t(0x30,0x4A,0x08), \ |
| 353 | rgb_t(0x41,0x5B,0x08), rgb_t(0x52,0x6C,0x08), rgb_t(0x63,0x7D,0x08), rgb_t(0x74,0x8E,0x0D), \ |
| 354 | rgb_t(0x85,0x9F,0x1E), rgb_t(0x96,0xB0,0x2F), rgb_t(0xA7,0xC1,0x40), rgb_t(0xB8,0xD2,0x51), \ |
| 355 | rgb_t(0xC9,0xE3,0x62), rgb_t(0xDA,0xF4,0x73), rgb_t(0xEB,0xFF,0x82), rgb_t(0xFC,0xFF,0x8E ) |
| 355 | 356 | |
| 356 | 357 | #define NTSC_LIGHT_ORANGE \ |
| 357 | | rgb_t(0x21,0x02,0x00), rgb_t(0x32,0x13,0x00), rgb_t(0x43,0x24,0x00), rgb_t(0x54,0x35,0x00), \ |
| 358 | | rgb_t(0x65,0x46,0x00), rgb_t(0x76,0x57,0x00), rgb_t(0x87,0x68,0x00), rgb_t(0x98,0x79,0x0C), \ |
| 359 | | rgb_t(0xA9,0x8A,0x1D), rgb_t(0xBA,0x9B,0x2E), rgb_t(0xCB,0xAC,0x3F), rgb_t(0xDC,0xBD,0x50), \ |
| 360 | | rgb_t(0xED,0xCE,0x61), rgb_t(0xFE,0xDF,0x72), rgb_t(0xFF,0xF0,0x87), rgb_t(0xFF,0xFF,0x9D ) |
| 358 | rgb_t(0x19,0x07,0x00), rgb_t(0x2A,0x18,0x00), rgb_t(0x3B,0x29,0x00), rgb_t(0x4C,0x3A,0x00), \ |
| 359 | rgb_t(0x5D,0x4B,0x00), rgb_t(0x6E,0x5C,0x00), rgb_t(0x7F,0x6D,0x00), rgb_t(0x90,0x7E,0x09), \ |
| 360 | rgb_t(0xA1,0x8F,0x1A), rgb_t(0xB2,0xA0,0x2B), rgb_t(0xC3,0xB1,0x3C), rgb_t(0xD4,0xC2,0x4D), \ |
| 361 | rgb_t(0xE5,0xD3,0x5E), rgb_t(0xF6,0xE4,0x6F), rgb_t(0xFF,0xF5,0x82), rgb_t(0xFF,0xFF,0x96 ) |
| 361 | 362 | |
| 362 | 363 | static const rgb_t a7800_palette[256*3] = |
| 363 | 364 | { |
| r29424 | r29425 | |
| 400 | 401 | }; |
| 401 | 402 | |
| 402 | 403 | /*************************************************************************** |
| 403 | | PALETTE - PHASE 24.7 SHIFT |
| 404 | PALETTE - 24.7 PHASE SHIFT |
| 404 | 405 | |
| 405 | 406 | |
| 406 | 407 | define NTSC_GREY |
| r29424 | r29425 | |
| 500 | 501 | rgb_t(0xD6,0xDD,0x5E), rgb_t(0xE7,0xEE,0x6F), rgb_t(0xF8,0xFF,0x80), rgb_t(0xFF,0xFF,0x8F ) |
| 501 | 502 | ***************************************************************************/ |
| 502 | 503 | |
| 504 | |
| 503 | 505 | /*************************************************************************** |
| 504 | | PALETTE - PHASE 25.2 SHIFT |
| 506 | PALETTE - 25.2 PHASE SHIFT |
| 505 | 507 | |
| 506 | 508 | |
| 507 | 509 | define NTSC_GREY |
| r29424 | r29425 | |
| 601 | 603 | rgb_t(0xDE,0xD8,0x5D), rgb_t(0xEF,0xE9,0x6E), rgb_t(0xFF,0xFA,0x80), rgb_t(0xFF,0xFF,0x92 ) |
| 602 | 604 | ***************************************************************************/ |
| 603 | 605 | |
| 606 | |
| 604 | 607 | /*************************************************************************** |
| 605 | | PALETTE - PHASE 25.7 SHIFT |
| 608 | PALETTE - 25.7 PHASE SHIFT |
| 606 | 609 | |
| 607 | 610 | |
| 608 | 611 | define NTSC_GREY |
| r29424 | r29425 | |
| 702 | 705 | rgb_t(0xE5,0xD3,0x5E), rgb_t(0xF6,0xE4,0x6F), rgb_t(0xFF,0xF5,0x82), rgb_t(0xFF,0xFF,0x96 ) |
| 703 | 706 | ***************************************************************************/ |
| 704 | 707 | |
| 708 | |
| 705 | 709 | /*************************************************************************** |
| 706 | | PALETTE - PHASE 26.7 SHIFT |
| 710 | PALETTE - 26.2 PHASE SHIFT |
| 707 | 711 | |
| 708 | 712 | |
| 713 | #define NTSC_GREY \ |
| 714 | rgb_t(0x00,0x00,0x00), rgb_t(0x11,0x11,0x11), rgb_t(0x22,0x22,0x22), rgb_t(0x33,0x33,0x33), \ |
| 715 | rgb_t(0x44,0x44,0x44), rgb_t(0x55,0x55,0x55), rgb_t(0x66,0x66,0x66), rgb_t(0x77,0x77,0x77), \ |
| 716 | rgb_t(0x88,0x88,0x88), rgb_t(0x99,0x99,0x99), rgb_t(0xAA,0xAA,0xAA), rgb_t(0xBB,0xBB,0xBB), \ |
| 717 | rgb_t(0xCC,0xCC,0xCC), rgb_t(0xDD,0xDD,0xDD), rgb_t(0xEE,0xEE,0xEE), rgb_t(0xFF,0xFF,0xFF ) |
| 718 | |
| 719 | #define NTSC_GOLD \ |
| 720 | rgb_t(0x1A,0x07,0x00), rgb_t(0x2B,0x18,0x00), rgb_t(0x3C,0x29,0x00), rgb_t(0x4D,0x3A,0x00), \ |
| 721 | rgb_t(0x5E,0x4B,0x00), rgb_t(0x6F,0x5C,0x00), rgb_t(0x80,0x6D,0x00), rgb_t(0x91,0x7E,0x09), \ |
| 722 | rgb_t(0xA2,0x8F,0x1A), rgb_t(0xB3,0xA0,0x2B), rgb_t(0xC4,0xB1,0x3C), rgb_t(0xD5,0xC2,0x4D), \ |
| 723 | rgb_t(0xE6,0xD3,0x5E), rgb_t(0xF7,0xE4,0x6F), rgb_t(0xFF,0xF5,0x83), rgb_t(0xFF,0xF7,0x97 ) |
| 724 | |
| 725 | #define NTSC_ORANGE \ |
| 726 | rgb_t(0x31,0x00,0x00), rgb_t(0x42,0x06,0x00), rgb_t(0x53,0x17,0x00), rgb_t(0x64,0x28,0x00), \ |
| 727 | rgb_t(0x75,0x39,0x00), rgb_t(0x86,0X4A,0x00), rgb_t(0x97,0x5B,0x0B), rgb_t(0xA8,0x6C,0x1C), \ |
| 728 | rgb_t(0xB9,0x7D,0x2D), rgb_t(0xCA,0x8E,0x3E), rgb_t(0xDB,0x9F,0x4F), rgb_t(0xEC,0xB0,0x60), \ |
| 729 | rgb_t(0xFD,0xC1,0x71), rgb_t(0xFF,0xD2,0x86), rgb_t(0xFF,0xE3,0x9D), rgb_t(0xFF,0xF4,0xB3 ) |
| 730 | |
| 731 | #define NTSC_RED_ORANGE \ |
| 732 | rgb_t(0x3E,0x00,0x00), rgb_t(0x4F,0x00,0x00), rgb_t(0x60,0x08,0x00), rgb_t(0x71,0x19,0x00), \ |
| 733 | rgb_t(0x82,0x2A,0x0F), rgb_t(0x93,0x3B,0x20), rgb_t(0xA4,0x4C,0x31), rgb_t(0xB5,0x5D,0x42), \ |
| 734 | rgb_t(0xC6,0x6E,0x53), rgb_t(0xD7,0x7F,0x64), rgb_t(0xE8,0x90,0x75), rgb_t(0xF9,0xA1,0x86), \ |
| 735 | rgb_t(0xFF,0xB2,0x9A), rgb_t(0xFF,0xC3,0xB0), rgb_t(0xFF,0xD4,0xC6), rgb_t(0xFF,0xE5,0xDC ) |
| 736 | |
| 737 | #define NTSC_PINK \ |
| 738 | rgb_t(0x3E,0x00,0x06), rgb_t(0x4F,0x00,0x12), rgb_t(0x60,0x00,0x1E), rgb_t(0x71,0x0E,0x2E), \ |
| 739 | rgb_t(0x82,0x1F,0x3F), rgb_t(0x93,0x30,0x50), rgb_t(0xA4,0x41,0x61), rgb_t(0xB5,0x52,0x72), \ |
| 740 | rgb_t(0xC6,0x63,0x83), rgb_t(0xD7,0x74,0x94), rgb_t(0xE8,0x85,0xA5), rgb_t(0xF9,0x96,0xB6), \ |
| 741 | rgb_t(0xFF,0xA7,0xCB), rgb_t(0xFF,0xB8,0xE1), rgb_t(0xFF,0xC9,0xEF), rgb_t(0xFF,0xDA,0xF4 ) |
| 742 | |
| 743 | #define NTSC_PURPLE \ |
| 744 | rgb_t(0x32,0x00,0x38), rgb_t(0x43,0x00,0x44), rgb_t(0x54,0x00,0x50), rgb_t(0x65,0x0C,0x5F), \ |
| 745 | rgb_t(0x76,0x1D,0x70), rgb_t(0x87,0x2E,0x81), rgb_t(0x98,0x3F,0x92), rgb_t(0xA9,0x50,0xA3), \ |
| 746 | rgb_t(0xBA,0x61,0xB4), rgb_t(0xCB,0x72,0xC5), rgb_t(0xDC,0x83,0xD6), rgb_t(0xED,0x94,0xE4), \ |
| 747 | rgb_t(0xFE,0xA5,0xE4), rgb_t(0xFF,0xB6,0xE9), rgb_t(0xFF,0xC7,0xEE), rgb_t(0xFF,0xD8,0xF3 ) |
| 748 | |
| 749 | #define NTSC_PURPLE_BLUE \ |
| 750 | rgb_t(0x1B,0x00,0x5F), rgb_t(0x2C,0x00,0x6B), rgb_t(0x3D,0x00,0x77), rgb_t(0x4E,0x11,0x88), \ |
| 751 | rgb_t(0x5F,0x22,0x99), rgb_t(0x70,0x33,0xAA), rgb_t(0x81,0x44,0xBB), rgb_t(0x92,0x55,0xCC), \ |
| 752 | rgb_t(0xA3,0x66,0xDD), rgb_t(0xB4,0x77,0xED), rgb_t(0xC5,0x88,0xED), rgb_t(0xD6,0x99,0xED), \ |
| 753 | rgb_t(0xE7,0xAA,0xED), rgb_t(0xF8,0xBB,0xED), rgb_t(0xFF,0xCC,0xF0), rgb_t(0xFF,0xDD,0xF5 ) |
| 754 | |
| 755 | #define NTSC_BLUE1 \ |
| 756 | rgb_t(0x00,0x00,0x72), rgb_t(0x10,0x00,0x7E), rgb_t(0x21,0x0D,0x8E), rgb_t(0x32,0x1E,0x9F), \ |
| 757 | rgb_t(0x43,0x2F,0xB0), rgb_t(0x54,0x40,0xC1), rgb_t(0x65,0x51,0xD2), rgb_t(0x76,0x62,0xE3), \ |
| 758 | rgb_t(0x87,0x73,0xF4), rgb_t(0x98,0x84,0xF9), rgb_t(0xA9,0x95,0xF9), rgb_t(0xBA,0xA6,0xF9), \ |
| 759 | rgb_t(0xCB,0xB7,0xF9), rgb_t(0xDC,0xC8,0xF9), rgb_t(0xED,0xD9,0xF9), rgb_t(0xFE,0xEA,0xF9 ) |
| 760 | |
| 761 | #define NTSC_BLUE2 \ |
| 762 | rgb_t(0x00,0x00,0x65), rgb_t(0x00,0x0C,0x7A), rgb_t(0x05,0x1D,0x8E), rgb_t(0x16,0x2E,0x9F), \ |
| 763 | rgb_t(0x27,0x3F,0xB0), rgb_t(0x38,0x50,0xC1), rgb_t(0x49,0x61,0xD2), rgb_t(0x5A,0x72,0xE3), \ |
| 764 | rgb_t(0x6B,0x83,0xF4), rgb_t(0x7C,0x94,0xFF), rgb_t(0x8D,0xA5,0xFF), rgb_t(0x9E,0xB6,0xFF), \ |
| 765 | rgb_t(0xAF,0xC7,0xFF), rgb_t(0xC0,0xD8,0xFF), rgb_t(0xD1,0xE9,0xFF), rgb_t(0xE2,0xFA,0xFF ) |
| 766 | |
| 767 | #define NTSC_LIGHT_BLUE \ |
| 768 | rgb_t(0x00,0x0D,0x48), rgb_t(0x00,0x1E,0x5E), rgb_t(0x00,0x2F,0x74), rgb_t(0x00,0x40,0x8A), \ |
| 769 | rgb_t(0x11,0x51,0x9B), rgb_t(0x22,0x62,0xAC), rgb_t(0x33,0x73,0xBD), rgb_t(0x44,0x84,0xCE), \ |
| 770 | rgb_t(0x55,0x95,0xDF), rgb_t(0x66,0xA6,0xF0), rgb_t(0x77,0xB7,0xFF), rgb_t(0x88,0xC8,0xFF), \ |
| 771 | rgb_t(0x99,0xD9,0xFF), rgb_t(0xAA,0xEA,0xFF), rgb_t(0xBB,0xFB,0xFF), rgb_t(0xCC,0xFF,0xFF ) |
| 772 | |
| 773 | #define NTSC_TURQUOISE \ |
| 774 | rgb_t(0x00,0x1C,0x1C), rgb_t(0x00,0x2D,0x32), rgb_t(0x00,0x3E,0x49), rgb_t(0x00,0x4F,0x5F), \ |
| 775 | rgb_t(0x05,0x60,0x73), rgb_t(0x16,0x71,0x84), rgb_t(0x27,0x82,0x95), rgb_t(0x38,0x93,0xA6), \ |
| 776 | rgb_t(0x49,0xA4,0xB7), rgb_t(0x5A,0xB5,0xC8), rgb_t(0x6B,0xC6,0xD9), rgb_t(0x7C,0xD7,0xEA), \ |
| 777 | rgb_t(0x8D,0xE8,0xFB), rgb_t(0x9E,0xF9,0xFF), rgb_t(0xAF,0xFF,0xFF), rgb_t(0xC0,0xFF,0xFF ) |
| 778 | |
| 779 | #define NTSC_GREEN_BLUE \ |
| 780 | rgb_t(0x00,0x25,0x0B), rgb_t(0x00,0x36,0x10), rgb_t(0x00,0x47,0x18), rgb_t(0x00,0x58,0x2E), \ |
| 781 | rgb_t(0x07,0x69,0x42), rgb_t(0x18,0x7A,0x53), rgb_t(0x29,0x8B,0x64), rgb_t(0x3A,0x9C,0x75), \ |
| 782 | rgb_t(0x4B,0xAD,0x86), rgb_t(0x5C,0xBE,0x97), rgb_t(0x6D,0xCF,0xA8), rgb_t(0x7E,0xE0,0xB9), \ |
| 783 | rgb_t(0x8F,0xF1,0xCA), rgb_t(0xA0,0xFF,0xDA), rgb_t(0xB1,0xFF,0xE6), rgb_t(0xC2,0xFF,0xF2 ) |
| 784 | |
| 785 | #define NTSC_GREEN \ |
| 786 | rgb_t(0x00,0x27,0x0C), rgb_t(0x00,0x38,0x11), rgb_t(0x00,0x49,0x16), rgb_t(0x04,0x5A,0x1A), \ |
| 787 | rgb_t(0x15,0x6B,0x1A), rgb_t(0x26,0x7C,0x22), rgb_t(0x37,0x8D,0x33), rgb_t(0x48,0x9E,0x44), \ |
| 788 | rgb_t(0x59,0xAF,0x55), rgb_t(0x6A,0xC0,0x66), rgb_t(0x7B,0xD1,0x77), rgb_t(0x8C,0xE2,0x88), \ |
| 789 | rgb_t(0x9D,0xF3,0x99), rgb_t(0xAE,0xFF,0xA8), rgb_t(0xBF,0xFF,0xB4), rgb_t(0xD0,0xFF,0xC0 ) |
| 790 | |
| 791 | #define NTSC_YELLOW_GREEN \ |
| 792 | rgb_t(0x00,0x21,0x0A), rgb_t(0x00,0x32,0x0F), rgb_t(0x0A,0x43,0x11), rgb_t(0x1B,0x54,0x11), \ |
| 793 | rgb_t(0x2C,0x65,0x11), rgb_t(0x3D,0x76,0x11), rgb_t(0x4E,0x87,0x11), rgb_t(0x5F,0x98,0x1E), \ |
| 794 | rgb_t(0x70,0xA9,0x2F), rgb_t(0x81,0xBA,0x40), rgb_t(0x92,0xCB,0x51), rgb_t(0xA3,0xDC,0x62), \ |
| 795 | rgb_t(0xB4,0xED,0x73), rgb_t(0xC5,0xFE,0x84), rgb_t(0xD6,0xFF,0x90), rgb_t(0xE7,0xFF,0x9C ) |
| 796 | |
| 797 | #define NTSC_ORANGE_GREEN \ |
| 798 | rgb_t(0x05,0x13,0x04), rgb_t(0x16,0x24,0x04), rgb_t(0x27,0x35,0x04), rgb_t(0x38,0x46,0x04), \ |
| 799 | rgb_t(0x49,0x57,0x04), rgb_t(0x5A,0x68,0x04), rgb_t(0x6B,0x79,0x04), rgb_t(0x7C,0x8A,0x09), \ |
| 800 | rgb_t(0x8D,0x9B,0x1A), rgb_t(0x9E,0xAC,0x2B), rgb_t(0xAF,0xBD,0x3C), rgb_t(0xC0,0xCE,0x4D), \ |
| 801 | rgb_t(0xD1,0xDF,0x5E), rgb_t(0xE2,0xF0,0x6F), rgb_t(0xF3,0xFF,0x80), rgb_t(0xFF,0xFF,0x8D ) |
| 802 | |
| 803 | #define NTSC_LIGHT_ORANGE \ |
| 804 | rgb_t(0x21,0x02,0x00), rgb_t(0x32,0x13,0x00), rgb_t(0x43,0x24,0x00), rgb_t(0x54,0x35,0x00), \ |
| 805 | rgb_t(0x65,0x46,0x00), rgb_t(0x76,0x57,0x00), rgb_t(0x87,0x68,0x00), rgb_t(0x98,0x79,0x0C), \ |
| 806 | rgb_t(0xA9,0x8A,0x1D), rgb_t(0xBA,0x9B,0x2E), rgb_t(0xCB,0xAC,0x3F), rgb_t(0xDC,0xBD,0x50), \ |
| 807 | rgb_t(0xED,0xCE,0x61), rgb_t(0xFE,0xDF,0x72), rgb_t(0xFF,0xF0,0x87), rgb_t(0xFF,0xFF,0x9D ) |
| 808 | ***************************************************************************/ |
| 809 | |
| 810 | |
| 811 | /*************************************************************************** |
| 812 | PALETTE - 26.7 PHASE SHIFT |
| 813 | |
| 814 | |
| 709 | 815 | define NTSC_GREY |
| 710 | 816 | rgb_t(0x00,0x00,0x00), rgb_t(0x11,0x11,0x11), rgb_t(0x22,0x22,0x22), rgb_t(0x33,0x33,0x33), \ |
| 711 | 817 | rgb_t(0x44,0x44,0x44), rgb_t(0x55,0x55,0x55), rgb_t(0x66,0x66,0x66), rgb_t(0x77,0x77,0x77), \ |
| r29424 | r29425 | |
| 805 | 911 | |
| 806 | 912 | |
| 807 | 913 | /*************************************************************************** |
| 808 | | PALETTE - PHASE 27.2 SHIFT |
| 914 | PALETTE - 27.2 PHASE SHIFT |
| 809 | 915 | |
| 810 | 916 | |
| 811 | 917 | define NTSC_GREY |
| r29424 | r29425 | |
| 1033 | 1139 | |
| 1034 | 1140 | /* video hardware */ |
| 1035 | 1141 | MCFG_SCREEN_ADD("screen", RASTER) |
| 1036 | | MCFG_SCREEN_RAW_PARAMS( 7159090, 456, 0, 320, 263, 26, 26 + 192 + 30 ) |
| 1142 | MCFG_SCREEN_RAW_PARAMS( 7159090, 456, 0, 320, 263, 27, 27 + 192 + 32 ) |
| 1037 | 1143 | MCFG_SCREEN_UPDATE_DRIVER(a7800_state, screen_update_a7800) |
| 1038 | 1144 | MCFG_SCREEN_PALETTE("palette") |
| 1039 | 1145 | |
| r29424 | r29425 | |
| 1072 | 1178 | // MCFG_TIMER_ADD_SCANLINE("scantimer", a7800_interrupt, "screen", 0, 1) |
| 1073 | 1179 | |
| 1074 | 1180 | MCFG_SCREEN_MODIFY( "screen" ) |
| 1075 | | MCFG_SCREEN_RAW_PARAMS( 7093788, 456, 0, 320, 313, 34, 34 + 228 + 30 ) |
| 1181 | MCFG_SCREEN_RAW_PARAMS( 7093788, 456, 0, 320, 313, 35, 35 + 228 + 32 ) |
| 1076 | 1182 | |
| 1077 | 1183 | MCFG_PALETTE_MODIFY("palette") |
| 1078 | 1184 | MCFG_PALETTE_INIT_OWNER(a7800_state, a7800p ) |
| r29424 | r29425 | |
| 1084 | 1190 | |
| 1085 | 1191 | /* devices */ |
| 1086 | 1192 | MCFG_DEVICE_REMOVE("riot") |
| 1087 | | MCFG_RIOT6532_ADD("riot", 3546894/3, a7800_r6532_interface) |
| 1193 | MCFG_RIOT6532_ADD("riot", CLK_PAL, a7800_r6532_interface) |
| 1088 | 1194 | |
| 1089 | 1195 | /* software lists */ |
| 1090 | 1196 | MCFG_DEVICE_REMOVE("cart_list") |
branches/new_menus/src/mame/drivers/4enlinea.c
| r29424 | r29425 | |
| 137 | 137 | 8952 (PIN 04) --|02 19|-- GAL (PIN 17) 8952 (PIN 08) --|02 19|-- GAL (PIN 16) |
| 138 | 138 | MAIN Z80 (D7) --|03 18|-- MAIN Z80 (D0) MAIN Z80 (D7) --|03 18|-- MAIN Z80 (D0) |
| 139 | 139 | 8952 (PIN 03) --|04 17|-- 8952 (PIN 40) 8952 (PIN 07) --|04 17|-- 8952 (PIN 36) |
| 140 | | MAIN Z80 (D6) --|05 16|-- MAIN Z80 (D1) MAIN Z80 (D6) --|05 16|-- MAIN Z80 (D1) |
| 140 | MAIN Z80 (D6) --|05 16|-- MAIN Z80 (D1) MAIN Z80 (D6) --|05 16|-- MAIN Z80 (D1) |
| 141 | 141 | 8952 (PIN 02) --|06 15|-- 8952 (PIN 39) 8952 (PIN 06) --|06 15|-- 8952 (PIN 35) |
| 142 | 142 | MAIN Z80 (D5) --|07 14|-- MAIN Z80 (D2) MAIN Z80 (D5) --|07 14|-- MAIN Z80 (D2) |
| 143 | 143 | 8952 (PIN 01) --|08 13|-- 8952 (PIN 38) 8952 (PIN 05) --|08 13|-- 8952 (PIN 34) |
| 144 | | MAIN Z80 (D4) --|09 12|-- MAIN Z80 (D3) MAIN Z80 (D4) --|09 12|-- MAIN Z80 (D3) |
| 144 | MAIN Z80 (D4) --|09 12|-- MAIN Z80 (D3) MAIN Z80 (D4) --|09 12|-- MAIN Z80 (D3) |
| 145 | 145 | GND --|10 11|-- 8952 (PIN 37) GND --|10 11|-- 8952 (PIN 33) |
| 146 | 146 | '-------' '-------' |
| 147 | 147 | |
| r29424 | r29425 | |
| 198 | 198 | #include "cpu/z80/z80.h" |
| 199 | 199 | #include "video/mc6845.h" |
| 200 | 200 | #include "sound/ay8910.h" |
| 201 | #include "bus/isa/isa.h" |
| 202 | #include "bus/isa/cga.h" |
| 203 | #include "video/cgapal.h" |
| 201 | 204 | |
| 202 | 205 | class _4enlinea_state : public driver_device |
| 203 | 206 | { |
| r29424 | r29425 | |
| 205 | 208 | _4enlinea_state(const machine_config &mconfig, device_type type, const char *tag) |
| 206 | 209 | : driver_device(mconfig, type, tag), |
| 207 | 210 | m_ay(*this, "aysnd"), |
| 208 | | m_videoram(*this, "videoram"), |
| 209 | | m_videoram2(*this, "videoram2"), |
| 210 | | m_maincpu(*this, "maincpu"), |
| 211 | | m_gfxdecode(*this, "gfxdecode"), |
| 212 | | m_screen(*this, "screen"), |
| 213 | | m_palette(*this, "palette") { } |
| 211 | m_maincpu(*this, "maincpu") |
| 212 | { } |
| 214 | 213 | |
| 215 | 214 | |
| 216 | 215 | required_device<ay8910_device> m_ay; |
| 217 | | required_shared_ptr<UINT8> m_videoram; |
| 218 | | required_shared_ptr<UINT8> m_videoram2; |
| 219 | 216 | |
| 220 | | DECLARE_WRITE8_MEMBER(crtc_config_w); |
| 221 | | DECLARE_WRITE8_MEMBER(crtc_mode_ctrl_w); |
| 222 | | DECLARE_WRITE8_MEMBER(crtc_colormode_w); |
| 223 | | DECLARE_READ8_MEMBER(crtc_status_r); |
| 224 | 217 | DECLARE_READ8_MEMBER(unk_e000_r); |
| 225 | 218 | DECLARE_READ8_MEMBER(unk_e001_r); |
| 219 | INTERRUPT_GEN_MEMBER(_4enlinea_irq); |
| 220 | UINT8 m_irq_count; |
| 226 | 221 | |
| 227 | 222 | virtual void machine_start(); |
| 228 | 223 | virtual void machine_reset(); |
| 229 | | virtual void video_start(); |
| 230 | | DECLARE_PALETTE_INIT(_4enlinea); |
| 231 | | UINT32 screen_update_4enlinea(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); |
| 232 | 224 | required_device<cpu_device> m_maincpu; |
| 233 | | required_device<gfxdecode_device> m_gfxdecode; |
| 234 | | required_device<screen_device> m_screen; |
| 235 | | required_device<palette_device> m_palette; |
| 236 | | |
| 237 | | DECLARE_WRITE8_MEMBER(vram_w); |
| 238 | | DECLARE_WRITE8_MEMBER(vram2_w); |
| 239 | | |
| 240 | 225 | }; |
| 241 | 226 | |
| 242 | 227 | |
| r29424 | r29425 | |
| 244 | 229 | * Video Hardware * |
| 245 | 230 | ***********************************/ |
| 246 | 231 | |
| 247 | | void _4enlinea_state::video_start() |
| 232 | class isa8_cga_4enlinea_device : public isa8_cga_device |
| 248 | 233 | { |
| 249 | | m_gfxdecode->gfx(0)->set_source(m_videoram); |
| 250 | | } |
| 234 | public: |
| 235 | // construction/destruction |
| 236 | isa8_cga_4enlinea_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 251 | 237 | |
| 252 | | UINT32 _4enlinea_state::screen_update_4enlinea(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) |
| 238 | virtual void device_start(); |
| 239 | virtual const rom_entry *device_rom_region() const; |
| 240 | }; |
| 241 | |
| 242 | const rom_entry *isa8_cga_4enlinea_device::device_rom_region() const |
| 253 | 243 | { |
| 254 | | /* note: chars are 16*12 pixels */ |
| 244 | return NULL; |
| 245 | } |
| 255 | 246 | |
| 256 | | int offset = 0; |
| 257 | | int offset2 = 0; |
| 247 | const device_type ISA8_CGA_4ENLINEA = &device_creator<isa8_cga_4enlinea_device>; |
| 258 | 248 | |
| 259 | | for (int y = 0; y < 200; y++) |
| 260 | | { |
| 261 | | UINT16* dstptr_bitmap = &bitmap.pix16(y); |
| 249 | isa8_cga_4enlinea_device::isa8_cga_4enlinea_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : |
| 250 | isa8_cga_device( mconfig, ISA8_CGA_4ENLINEA, "ISA8_CGA_4ENLINEA", tag, owner, clock, "4enlinea_cga", __FILE__) |
| 251 | { |
| 252 | } |
| 262 | 253 | |
| 263 | | for (int x = 0; x < 320; x += 4) |
| 264 | | { |
| 265 | | UINT8 pix; |
| 266 | 254 | |
| 267 | | if (y & 1) pix = m_videoram2[offset2++]; |
| 268 | | else pix = m_videoram[offset++]; |
| 269 | 255 | |
| 270 | | dstptr_bitmap[x + 3] = (pix >> 0) & 0x3; |
| 271 | | dstptr_bitmap[x + 2] = (pix >> 2) & 0x3; |
| 272 | | dstptr_bitmap[x + 1] = (pix >> 4) & 0x3; |
| 273 | | dstptr_bitmap[x + 0] = (pix >> 6) & 0x3; |
| 274 | | } |
| 275 | | } |
| 256 | void isa8_cga_4enlinea_device::device_start() |
| 257 | { |
| 258 | if (m_palette != NULL && !m_palette->started()) |
| 259 | throw device_missing_dependencies(); |
| 276 | 260 | |
| 277 | | return 0; |
| 278 | | } |
| 261 | set_isa_device(); |
| 262 | m_vram_size = 0x4000; |
| 263 | m_vram.resize(m_vram_size); |
| 279 | 264 | |
| 265 | m_update_row = NULL; |
| 266 | m_isa->install_device(0x3d0, 0x3df, 0, 0, read8_delegate( FUNC(isa8_cga_device::io_read), this ), write8_delegate( FUNC(isa8_cga_device::io_write), this ) ); |
| 267 | m_isa->install_bank(0x8000, 0xbfff, 0, 0, "bank1", m_vram); |
| 280 | 268 | |
| 281 | | WRITE8_MEMBER(_4enlinea_state::vram_w) |
| 282 | | { |
| 283 | | m_videoram[offset] = data; |
| 284 | | // m_gfxdecode->gfx(0)->mark_dirty(offset/16); |
| 285 | | } |
| 269 | /* Initialise the cga palette */ |
| 270 | int i; |
| 286 | 271 | |
| 287 | | WRITE8_MEMBER(_4enlinea_state::vram2_w) |
| 288 | | { |
| 289 | | m_videoram2[offset] = data; |
| 290 | | // m_gfxdecode->gfx(0)->mark_dirty(offset/16); |
| 291 | | } |
| 292 | | |
| 293 | | WRITE8_MEMBER(_4enlinea_state::crtc_config_w) |
| 294 | | { |
| 295 | | /* Bit 6 enables the CGA mode, otherwise is MGA */ |
| 296 | | if(data & 0x40) |
| 272 | for ( i = 0; i < CGA_PALETTE_SETS * 16; i++ ) |
| 297 | 273 | { |
| 298 | | logerror("CRTC config mode (3BFh): CGA\n"); |
| 274 | m_palette->set_pen_color( i, cga_palette[i][0], cga_palette[i][1], cga_palette[i][2] ); |
| 299 | 275 | } |
| 300 | | else |
| 276 | |
| 277 | i = 0x8000; |
| 278 | for ( int r = 0; r < 32; r++ ) |
| 301 | 279 | { |
| 302 | | logerror("CRTC config mode (3BFh): MGA\n"); |
| 280 | for ( int g = 0; g < 32; g++ ) |
| 281 | { |
| 282 | for ( int b = 0; b < 32; b++ ) |
| 283 | { |
| 284 | m_palette->set_pen_color( i, r << 3, g << 3, b << 3 ); |
| 285 | i++; |
| 286 | } |
| 287 | } |
| 303 | 288 | } |
| 304 | | } |
| 305 | 289 | |
| 306 | | WRITE8_MEMBER(_4enlinea_state::crtc_mode_ctrl_w) |
| 307 | | { |
| 308 | | /* Bit 3 enables/disables the video (see the notes above) */ |
| 309 | | logerror("CRTC mode control (3D8h): %02x\n", data); |
| 290 | // astring tempstring; |
| 291 | // m_chr_gen_base = memregion(subtag(tempstring, "gfx1"))->base(); |
| 292 | // m_chr_gen = m_chr_gen_base + m_chr_gen_offset[1]; |
| 310 | 293 | } |
| 311 | 294 | |
| 312 | | WRITE8_MEMBER(_4enlinea_state::crtc_colormode_w) |
| 313 | | { |
| 314 | | logerror("CRTC color mode (3D9h): %02x\n", data); |
| 315 | | } |
| 316 | 295 | |
| 317 | | READ8_MEMBER(_4enlinea_state::crtc_status_r) |
| 318 | | { |
| 319 | | /*----- bits ----- |
| 320 | | 7 6 5 4 3 2 1 0 For CGA Mode. |
| 321 | | x x x x - - - - (bits 4-5-6-7 are unused) |
| 322 | | | | | | |
| 323 | | | | | '-- 0: Display active period. |
| 324 | | | | | 1: Non-display period. |
| 325 | | | | | |
| 326 | | | | '---- 0: Light pen reset. |
| 327 | | | | 1: Light pen set. |
| 328 | | | | |
| 329 | | | '------ 0: Light pen switch off. |
| 330 | | | 1: Light pen switch on. |
| 331 | | | |
| 332 | | '-------- 0: Non-vertical sync period. |
| 333 | | 1: Vertical sync period. |
| 334 | | |
| 335 | | */ |
| 336 | | return (m_screen->vpos() >= 200) ? 0x80 : 0x00; // bit 7 is suppossed to be unused in CGA mode |
| 337 | | } |
| 338 | | |
| 339 | 296 | READ8_MEMBER(_4enlinea_state::unk_e000_r) |
| 340 | 297 | { |
| 341 | 298 | logerror("read e000\n"); |
| r29424 | r29425 | |
| 350 | 307 | // return (machine().rand() & 0x0f); // after 30 seconds, random gfx appear on the screen. |
| 351 | 308 | } |
| 352 | 309 | |
| 353 | | |
| 354 | 310 | /*********************************** |
| 355 | 311 | * Memory Map Information * |
| 356 | 312 | ***********************************/ |
| 357 | 313 | |
| 358 | 314 | static ADDRESS_MAP_START( main_map, AS_PROGRAM, 8, _4enlinea_state ) |
| 359 | 315 | AM_RANGE(0x0000, 0x7fff) AM_ROM |
| 360 | | AM_RANGE(0x8000, 0x9fff) AM_RAM_WRITE(vram_w) AM_SHARE("videoram") // even lines |
| 361 | | AM_RANGE(0xa000, 0xbfff) AM_RAM_WRITE(vram2_w) AM_SHARE("videoram2") // odd lines |
| 316 | // AM_RANGE(0x8000, 0xbfff) AM_RAM // CGA VRAM |
| 362 | 317 | AM_RANGE(0xc000, 0xdfff) AM_RAM |
| 363 | 318 | |
| 364 | 319 | AM_RANGE(0xe000, 0xe000) AM_READ(unk_e000_r) |
| r29424 | r29425 | |
| 372 | 327 | static ADDRESS_MAP_START( main_portmap, AS_IO, 8, _4enlinea_state ) |
| 373 | 328 | ADDRESS_MAP_GLOBAL_MASK(0x3ff) |
| 374 | 329 | |
| 375 | | AM_RANGE(0x3d4, 0x3d4) AM_DEVWRITE("crtc", mc6845_device, address_w) |
| 376 | | AM_RANGE(0x3d5, 0x3d5) AM_DEVWRITE("crtc", mc6845_device, register_w) |
| 377 | | AM_RANGE(0x3d8, 0x3d8) AM_WRITE(crtc_mode_ctrl_w) |
| 378 | | AM_RANGE(0x3d9, 0x3d9) AM_WRITE(crtc_colormode_w) |
| 379 | | AM_RANGE(0x3da, 0x3da) AM_READ(crtc_status_r) |
| 380 | | AM_RANGE(0x3bf, 0x3bf) AM_WRITE(crtc_config_w) |
| 381 | | |
| 330 | // AM_RANGE(0x3d4, 0x3df) CGA regs |
| 382 | 331 | ADDRESS_MAP_END |
| 383 | 332 | |
| 384 | 333 | |
| r29424 | r29425 | |
| 423 | 372 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) |
| 424 | 373 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) |
| 425 | 374 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 375 | |
| 376 | |
| 377 | PORT_START( "pcvideo_cga_config" ) |
| 378 | PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) |
| 426 | 379 | INPUT_PORTS_END |
| 427 | 380 | |
| 428 | 381 | |
| r29424 | r29425 | |
| 430 | 383 | * Graphics Layouts * |
| 431 | 384 | ***********************************/ |
| 432 | 385 | |
| 433 | | static const gfx_layout charlayout = |
| 434 | | { |
| 435 | | 8,8, |
| 436 | | 0x4000/16, |
| 437 | | 2, |
| 438 | | { 0, 1 }, |
| 439 | | { 0, 2, 4, 6, 8, 10, 12, 14 }, |
| 440 | | { 0*16, 1*16, 2*16, 3*16, 4*16, 5*16, 6*16, 7*16 }, |
| 441 | | 8*16 |
| 442 | | }; |
| 443 | 386 | |
| 387 | |
| 444 | 388 | /**************************************** |
| 445 | 389 | * Graphics Decode Information * |
| 446 | 390 | ****************************************/ |
| 447 | 391 | |
| 448 | | static GFXDECODE_START( 4enlinea ) |
| 449 | | GFXDECODE_ENTRY( NULL, 0, charlayout, 0, 1 ) |
| 450 | | GFXDECODE_END |
| 392 | //static GFXDECODE_START( 4enlinea ) |
| 393 | //GFXDECODE_END |
| 451 | 394 | |
| 452 | 395 | |
| 453 | 396 | /**************************************** |
| r29424 | r29425 | |
| 469 | 412 | * CRTC Interface * |
| 470 | 413 | **********************************/ |
| 471 | 414 | |
| 472 | | static MC6845_ON_UPDATE_ADDR_CHANGED(crtc_addr) |
| 473 | | { |
| 474 | 415 | |
| 475 | | } |
| 476 | 416 | |
| 477 | | static MC6845_INTERFACE( mc6845_intf ) |
| 478 | | { |
| 479 | | false, /* show border area */ |
| 480 | | 0,0,0,0, /* visarea adjustment */ |
| 481 | | 8, /* number of pixels per video memory address */ |
| 482 | | NULL, /* before pixel update callback */ |
| 483 | | NULL, /* row update callback */ |
| 484 | | NULL, /* after pixel update callback */ |
| 485 | | DEVCB_NULL, /* callback for display state changes */ |
| 486 | | DEVCB_NULL, /* callback for cursor state changes */ |
| 487 | | DEVCB_NULL, /* HSYNC callback */ |
| 488 | | DEVCB_NULL, /* VSYNC callback */ |
| 489 | | crtc_addr /* update address callback */ |
| 490 | | }; |
| 491 | | |
| 492 | | |
| 493 | 417 | /*********************************** |
| 494 | 418 | * Sound Interface * |
| 495 | 419 | ***********************************/ |
| r29424 | r29425 | |
| 509 | 433 | * Machine Drivers * |
| 510 | 434 | ***********************************/ |
| 511 | 435 | |
| 436 | SLOT_INTERFACE_START( 4enlinea_isa8_cards ) |
| 437 | SLOT_INTERFACE_INTERNAL("4enlinea", ISA8_CGA_4ENLINEA) |
| 438 | SLOT_INTERFACE_END |
| 439 | |
| 440 | static const isa8bus_interface _4enlinea_isabus_intf = |
| 441 | { |
| 442 | // interrupts |
| 443 | DEVCB_NULL, |
| 444 | DEVCB_NULL, |
| 445 | DEVCB_NULL, |
| 446 | DEVCB_NULL, |
| 447 | DEVCB_NULL, |
| 448 | DEVCB_NULL, |
| 449 | |
| 450 | // dma request |
| 451 | DEVCB_NULL, |
| 452 | DEVCB_NULL, |
| 453 | DEVCB_NULL |
| 454 | }; |
| 455 | |
| 456 | /* TODO: irq sources are unknown */ |
| 457 | INTERRUPT_GEN_MEMBER(_4enlinea_state::_4enlinea_irq) |
| 458 | { |
| 459 | if(m_irq_count == 0) |
| 460 | device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); |
| 461 | else |
| 462 | device.execute().set_input_line(0, HOLD_LINE); |
| 463 | |
| 464 | m_irq_count++; |
| 465 | m_irq_count&=3; |
| 466 | } |
| 467 | |
| 512 | 468 | static MACHINE_CONFIG_START( 4enlinea, _4enlinea_state ) |
| 513 | 469 | |
| 514 | 470 | /* basic machine hardware */ |
| 515 | 471 | MCFG_CPU_ADD("maincpu", Z80, PRG_CPU_CLOCK) |
| 516 | 472 | MCFG_CPU_PROGRAM_MAP(main_map) |
| 517 | 473 | MCFG_CPU_IO_MAP(main_portmap) |
| 518 | | MCFG_CPU_VBLANK_INT_DRIVER("screen", _4enlinea_state, nmi_line_pulse) |
| 519 | | MCFG_CPU_PERIODIC_INT_DRIVER(_4enlinea_state, irq0_line_hold, 4*60) |
| 474 | MCFG_CPU_PERIODIC_INT_DRIVER(_4enlinea_state, _4enlinea_irq, 60) //TODO |
| 475 | // MCFG_CPU_PERIODIC_INT_DRIVER(_4enlinea_state, irq0_line_hold, 4*35) |
| 520 | 476 | |
| 521 | 477 | MCFG_CPU_ADD("audiocpu", Z80, SND_CPU_CLOCK) |
| 522 | 478 | MCFG_CPU_PROGRAM_MAP(audio_map) |
| 523 | 479 | MCFG_CPU_IO_MAP(audio_portmap) |
| 524 | 480 | |
| 525 | | /* video hardware */ |
| 526 | | MCFG_SCREEN_ADD("screen", RASTER) |
| 527 | | MCFG_SCREEN_REFRESH_RATE(60) |
| 528 | | MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| 529 | | MCFG_SCREEN_SIZE(320, 200) |
| 530 | | MCFG_SCREEN_VISIBLE_AREA(0, 320-1, 0, 200-1) |
| 531 | | MCFG_SCREEN_UPDATE_DRIVER(_4enlinea_state, screen_update_4enlinea) |
| 532 | | MCFG_SCREEN_PALETTE("palette") |
| 481 | MCFG_ISA8_BUS_ADD("isa", ":maincpu", _4enlinea_isabus_intf) |
| 482 | MCFG_ISA8_SLOT_ADD("isa", "isa1", 4enlinea_isa8_cards, "4enlinea", true) |
| 533 | 483 | |
| 534 | | MCFG_GFXDECODE_ADD("gfxdecode", "palette", 4enlinea) |
| 535 | | MCFG_PALETTE_ADD("palette", 256) |
| 536 | 484 | |
| 537 | 485 | /* 6845 clock is a guess, since it's a UM6845R embedded in the UM487F. |
| 538 | 486 | CRTC_CLOCK is 8MHz, entering for pin 1 of UM487F. This clock is used |
| r29424 | r29425 | |
| 542 | 490 | CRTC_CLOCK / 4.5 = 59.521093 Hz. |
| 543 | 491 | CRTC_CLOCK / 5.0 = 53.569037 Hz. |
| 544 | 492 | */ |
| 545 | | // MCFG_MC6845_ADD("crtc", MC6845, "screen", CRTC_CLOCK / 2, mc6845_intf) // seems that MC6845 doesn't support the game mode |
| 546 | | MCFG_MC6845_ADD("crtc", R6545_1, "screen", CRTC_CLOCK / 4.5, mc6845_intf) |
| 547 | 493 | |
| 548 | 494 | /* sound hardware */ |
| 549 | 495 | MCFG_SPEAKER_STANDARD_MONO("mono") |