Previous 15994 Revisions Next

r4256 Friday 13th February, 2009 at 09:46:14 UTC by Dirk Best
[AMSTRAD] Updated to use the new centronics support, added support for bit 8 of printer data for CPC+
[docs]messnew.txt
[src/mess/devices]printer.c printer.h
[src/mess/drivers]amstrad.c
[src/mess/machine]amstrad.c ctronics.c ctronics.h

src/mess/machine/amstrad.c
r4255r4256
4040#include "machine/8255ppi.h"
4141#include "machine/mc146818.h"
4242#include "machine/nec765.h"
43#include "machine/ctronics.h"
4344#include "devices/dsk.h"
4445#include "devices/cassette.h"
45#include "devices/printer.h"
4646#include "devices/snapquik.h"
4747#include "includes/amstrad.h"
4848#include "sound/ay8910.h"
r4255r4256
128128static UINT8 ppi_port_inputs[3];
129129static UINT8 ppi_port_outputs[3];
130130
131static UINT8 previous_printer_data_byte;
132
133131static int aleste_rtc_function;
134132static int aleste_fdc_int;
135133
r4255r4256
269267static void amstrad_rethinkMemory(running_machine *machine);
270268
271269
272static const device_config *printer_device(running_machine *machine)
273{
274   return devtag_get_device(machine, PRINTER, "printer");
275}
276
277
278270/* Initialise the palette */
279271PALETTE_INIT( amstrad_cpc )
280272{
r4255r4256
400392   for(i=0; i<32; i++)
401393   {
402394      int r,g,b;
403     
395
404396      b = (pal[0x140+i] >> 4) & 0x03;
405397      g = (pal[0x140+i] >> 2) & 0x03;
406398      r = pal[0x140+i] & 0x03;
407     
399
408400      r = (r << 6);
409401      g = (g << 6);
410402      b = (b << 6);
411403
412404      palette_set_color_rgb(machine, i, r, g, b);
413405   }
414   
406
415407   /* MSX colour palette is 6-bit RGB */
416408   for(i=0; i<64; i++)
417409   {
r4255r4256
786778   /* Apply vertical background scrolling */
787779   ra += ( ( amstrad_plus_asic_ram[0x2804] >> 4 ) & 0x07 );
788780   if ( ra > 7 )
789   {   
781   {
790782      ma += x_count;
791   }   
783   }
792784
793785   for ( i = 0; i < x_count; i++ )
794786   {
r4255r4256
841833   /* Apply vertical background scrolling */
842834   ra += ( ( amstrad_plus_asic_ram[0x2804] >> 4 ) & 0x07 );
843835   if ( ra > 7 )
844   {   
836   {
845837      ma += x_count;
846   }   
838   }
847839
848840   for ( i = 0; i < x_count; i++ )
849841   {
r4255r4256
16451637      {
16461638         bank_base = &memory_region(machine, "main")[0x010000];
16471639      }
1648      else
1640      else
16491641      {
16501642         if(aleste_mode & 0x04)
16511643            bank_base = Aleste_RamBanks[0];
r4255r4256
17321724   UINT8 *bank_base = NULL;
17331725
17341726   /* b3 : "1" Upper rom area disable or "0" Upper rom area enable */
1735   if ( ! ( gate_array.mrer & 0x08 ) )
1727   if ( ! ( gate_array.mrer & 0x08 ) )
17361728   {
17371729      bank_base = Amstrad_ROM_Table[ gate_array.upper_bank ];
17381730   }
1739   else
1731   else
17401732   {
17411733      if(aleste_mode & 0x04)
17421734         bank_base = Aleste_RamBanks[3];
r4255r4256
24322424   device_config *fdc = (device_config*)devtag_get_device( space->machine, NEC765A, "nec765");
24332425   device_config *mc6845 = (device_config *) devtag_get_device( space->machine, MC6845, "mc6845" );
24342426
2435   if ((offset & (1<<15)) == 0)
2427   static int printer_bit8_selected = FALSE;
2428
2429   if ((offset & (1<<15)) == 0)
24362430   {
24372431      if(aleste_mode & 0x04) // Aleste mode
24382432      {
r4255r4256
24412435      else
24422436      {
24432437         /* if b15 = 0 and b14 = 1 : Gate-Array Write Selected*/
2444         if ((offset & (1<<14)) != 0)
2438         if ((offset & (1<<14)) != 0)
24452439               amstrad_GateArray_write(space->machine, data);
24462440
24472441         /* if b15 = 0 : RAM Configuration Write Selected*/
r4255r4256
24592453         mc6845_address_w( mc6845, 0, data );
24602454         if ( amstrad_system_type == SYSTEM_PLUS || amstrad_system_type == SYSTEM_GX4000 )
24612455            amstrad_plus_seqcheck(data);
2456
2457         /* printer port d7 */
2458         if (data == 0x0c && amstrad_system_type == SYSTEM_PLUS)
2459            printer_bit8_selected = TRUE;
2460
24622461         break;
24632462      case 0x01:      /* Write to selected internal 6845 register Write Only */
24642463         video_screen_update_partial( space->machine->primary_screen, video_screen_get_vpos( space->machine->primary_screen ) );
24652464         mc6845_register_w( mc6845, 0, data );
2465
2466         /* printer port bit 8 */
2467         if (printer_bit8_selected && amstrad_system_type == SYSTEM_PLUS)
2468         {
2469            const device_config *printer = devtag_get_device(space->machine, CENTRONICS, "centronics");
2470            centronics_d7_w(printer, BIT(data, 3));
2471            printer_bit8_selected = FALSE;
2472         }
2473
24662474         break;
24672475      default:
24682476         break;
r4255r4256
24822490   {
24832491      if ((offset & (1<<12)) == 0)
24842492      {
2485         /* on CPC, write to printer through LS chip */
2486         /* the amstrad is crippled with a 7-bit port :( */
2487         /* bit 7 of the data is the printer /strobe */
2493         const device_config *printer = devtag_get_device(space->machine, CENTRONICS, "centronics");
24882494
2489         /* strobe state changed? */
2490         if (((previous_printer_data_byte^data) & (1<<7)) !=0 )
2491         {
2492            /* check for only one transition */
2493            if ((data & (1<<7)) == 0)
2494            {
2495               /* output data to printer */
2496               printer_output(printer_device(space->machine), data & 0x07f);
2497            }
2498         }
2499         previous_printer_data_byte = data;
2495         /* CPC has a 7-bit data port, bit 8 is the STROBE signal */
2496         centronics_data_w(printer, 0, data & 0x7f);
2497         centronics_strobe_w(printer, BIT(data, 7));
25002498      }
25012499   }
25022500
r4255r4256
28552853static void update_psg(running_machine *machine)
28562854{
28572855   const address_space *space = cpu_get_address_space(machine->cpu[0], ADDRESS_SPACE_PROGRAM);
2858   
2856
28592857   if(aleste_mode & 0x20)  // RTC selected
28602858   {
28612859      switch(aleste_rtc_function)
r4255r4256
28722870      }
28732871      return;
28742872   }
2875  switch (amstrad_Psg_FunctionSelected)
2873  switch (amstrad_Psg_FunctionSelected)
28762874  {
2877     case 0:
2875     case 0:
28782876      {/* Inactive */
28792877      } break;
2880     case 1:
2878     case 1:
28812879      {/* b6 = 1 ? : Read from selected PSG register and make the register data available to PPI Port A */
28822880           ppi_port_inputs[amstrad_ppi_PortA] = ay8910_read_port_0_r(space, 0);
2883        }
2881        }
28842882      break;
2885     case 2:
2883     case 2:
28862884      {/* b7 = 1 ? : Write to selected PSG register and write data to PPI Port A */
28872885           ay8910_write_port_0_w(space, 0, ppi_port_outputs[amstrad_ppi_PortA]);
2888        }
2886        }
28892887      break;
2890     case 3:
2888     case 3:
28912889      {/* b6 and b7 = 1 ? : The register will now be selected and the user can read from or write to it.  The register will remain selected until another is chosen.*/
28922890           ay8910_control_port_0_w(space, 0, ppi_port_outputs[amstrad_ppi_PortA]);
28932891         prev_reg = ppi_port_outputs[amstrad_ppi_PortA];
2894        }
2892        }
28952893      break;
28962894     default: {
28972895    } break;
r4255r4256
29522950/* Set b6 with Parallel/Printer port ready */
29532951   if(amstrad_system_type != SYSTEM_GX4000)
29542952   {
2955      if (printer_is_ready(printer_device(device->machine))==0 ) {
2956         data |= (1<<6);
2957      }
2953      const device_config *printer = devtag_get_device(device->machine, CENTRONICS, "centronics");
2954      data |= centronics_busy_r(printer) << 6;
29582955   }
29592956/* Set b4-b1 50Hz/60Hz state and manufacturer name defined by links on PCB */
29602957   data |= (ppi_port_inputs[amstrad_ppi_PortB] & 0x1e);
r4255r4256
30433040   If keyboard matrix line 11-14 are selected, the byte is always &ff.
30443041   After testing on a real CPC, it is found that these never change, they always return &FF. */
30453042
3046   static const char *const keynames[] = { "keyboard_row_0", "keyboard_row_1", "keyboard_row_2", "keyboard_row_3", "keyboard_row_4",
3043   static const char *const keynames[] = { "keyboard_row_0", "keyboard_row_1", "keyboard_row_2", "keyboard_row_3", "keyboard_row_4",
30473044                              "keyboard_row_5", "keyboard_row_6", "keyboard_row_7", "keyboard_row_8", "keyboard_row_9",
30483045                              "keyboard_row_10" };
30493046
3050   if ( ( ppi_port_outputs[amstrad_ppi_PortC] & 0x0F ) > 10)
3047   if ( ( ppi_port_outputs[amstrad_ppi_PortC] & 0x0F ) > 10)
30513048   {
30523049      return 0xFF;
3053   }
3054   else
3050   }
3051   else
30553052   {
30563053      if(aleste_mode == 0x08 && ( ppi_port_outputs[amstrad_ppi_PortC] & 0x0F ) == 10)
30573054         return 0xff;
r4255r4256
32133210static void amstrad_common_init(running_machine *machine)
32143211{
32153212   const address_space *space = cpu_get_address_space(machine->cpu[0], ADDRESS_SPACE_PROGRAM);
3216   
3213
32173214   aleste_mode = 0;
32183215
32193216   gate_array.mrer = 0;
r4255r4256
32943291   amstrad_common_init(machine);
32953292   amstrad_reset_machine(machine);
32963293//   amstrad_init_palette(machine);
3297   
3294
32983295   multiface_init();
32993296
33003297}
r4255r4256
33413338   amstrad_plus_asic_ram[0x2805] = 0x01;  // interrupt vector is undefined at startup, except that bit 0 is always 1.
33423339   AmstradCPC_GA_SetRamConfiguration(machine);
33433340   amstrad_GateArray_write(machine, 0x081); // Epyx World of Sports requires upper ROM to be enabled by default
3344   
3341
33453342   //  multiface_init();
33463343}
33473344
src/mess/machine/ctronics.c
r4255r4256
3333   int busy;
3434   int ack;
3535   int auto_fd;
36   int pe;
37   int fault;
3638 
3739   UINT8 data;
3840};
r4255r4256
7375{
7476   centronics_state *centronics = get_safe_token(device);
7577   const centronics_interface *intf = device->static_config;
76   char printer_tag[256];
7778 
7879   /* validate some basic stuff */
7980   assert(device->static_config != NULL);
8081 
8182   /* get printer device */
82   strcpy(printer_tag, device->tag);
83   strcat(printer_tag, "_p");
84   centronics->printer = devtag_get_device(device->machine, PRINTER, printer_tag);
85 
83   centronics->printer = devtag_get_device(device->machine, PRINTER, device->tag);
8684   assert(centronics->printer != NULL);
8785 
8886   /* make sure it's running */
r4255r4256
107105 
108106static DEVICE_RESET( centronics )
109107{
110   centronics_state *centronics = get_safe_token(device);
111   centronics->busy = printer_is_ready(centronics->printer) ? FALSE : TRUE;
112108}
113109 
114110static DEVICE_SET_INFO( centronics )
r4255r4256
149145***************************************************************************/
150146 
151147/*-------------------------------------------------
152    update_busy_state - check printer device
153    status and update busy state
148    centronics_printer_online - callback that
149    sets us busy when the printer goes offline
154150-------------------------------------------------*/
155151 
156static int update_busy_state(const device_config *device)
152void centronics_printer_online(const device_config *device, int state)
157153{
158   centronics_state *centronics = get_safe_token(device);
159   centronics->busy = printer_is_ready(centronics->printer) ? FALSE : TRUE;
160   return centronics->busy;
154   const device_config *c = devtag_get_device(device->machine, CENTRONICS, device->tag);
155   centronics_state *centronics = get_safe_token(c);
156 
157   /* when going online, set PE and FAULT high and BUSY low */
158   centronics->pe = state;
159   centronics->fault = state;
160   centronics->busy = !state;
161161}
162162 
163163 
r4255r4256
214214 
215215 
216216/*-------------------------------------------------
217    set_line - helper to set individual bits
218-------------------------------------------------*/
219 
220static void set_line(const device_config *device, int line, int state)
221{
222   centronics_state *centronics = get_safe_token(device);
223 
224   if (state)
225      centronics->data |= 1 << line;
226   else
227      centronics->data &= ~(1 << line);
228}
229 
230 
231/*-------------------------------------------------
232    centronics_dx_w - write line dx print data
233-------------------------------------------------*/
234 
235WRITE_LINE_DEVICE_HANDLER( centronics_d0_w ) { set_line(device, 0, state); }
236WRITE_LINE_DEVICE_HANDLER( centronics_d1_w ) { set_line(device, 1, state); }
237WRITE_LINE_DEVICE_HANDLER( centronics_d2_w ) { set_line(device, 2, state); }
238WRITE_LINE_DEVICE_HANDLER( centronics_d3_w ) { set_line(device, 3, state); }
239WRITE_LINE_DEVICE_HANDLER( centronics_d4_w ) { set_line(device, 4, state); }
240WRITE_LINE_DEVICE_HANDLER( centronics_d5_w ) { set_line(device, 5, state); }
241WRITE_LINE_DEVICE_HANDLER( centronics_d6_w ) { set_line(device, 6, state); }
242WRITE_LINE_DEVICE_HANDLER( centronics_d7_w ) { set_line(device, 7, state); }
243 
244 
245/*-------------------------------------------------
217246    centronics_strobe_w - signal that data is
218247    ready
219248-------------------------------------------------*/
r4255r4256
222251{
223252   centronics_state *centronics = get_safe_token(device);
224253 
225   /* ignore if we are busy */
226   if (state == FALSE && centronics->busy == FALSE)
254   /* look for a high -> low transition */
255   if (centronics->strobe == TRUE && state == FALSE && centronics->busy == FALSE)
227256   {
228257      /* STROBE has gone low, data is ready */
229258      timer_set(device->machine, ATTOTIME_IN_NSEC(250), centronics, TRUE, busy_callback);
r4255r4256
307336 
308337READ_LINE_DEVICE_HANDLER( centronics_pe_r )
309338{
310   /* use the busy line as pe line for now */
311   return !update_busy_state(device);
339   centronics_state *centronics = get_safe_token(device);
340   return centronics->pe;
312341}
313342 
314343 
r4255r4256
343372 
344373READ_LINE_DEVICE_HANDLER( centronics_fault_r )
345374{
346   /* use the busy line as fault line for now */
347   return !update_busy_state(device);
375   centronics_state *centronics = get_safe_token(device);
376   return centronics->fault;
348377}
src/mess/machine/ctronics.h
r4255r4256
2727 
2828 
2929/***************************************************************************
30    DEVICE CONFIGURATION MACROS
31***************************************************************************/
32 
33#define CENTRONICS DEVICE_GET_INFO_NAME(centronics)
34 
35#define MDRV_CENTRONICS_ADD(_tag, _intf) \
36   MDRV_PRINTER_ADD(_tag"_p") \
37   MDRV_DEVICE_ADD(_tag, CENTRONICS, 0) \
38   MDRV_DEVICE_CONFIG(_intf)
39 
40#define MDRV_CENTRONICS_REMOVE(_tag) \
41   MDRV_PRINTER_REMOVE(_tag"_p") \
42   MDRV_DEVICE_REMOVE(_tag, CENTRONICS)
43 
44 
45/***************************************************************************
4630    FUNCTION PROTOTYPES
4731***************************************************************************/
4832 
r4255r4256
5034 
5135WRITE8_DEVICE_HANDLER( centronics_data_w );
5236 
37/* access to the individual bits */
38WRITE_LINE_DEVICE_HANDLER( centronics_d0_w );
39WRITE_LINE_DEVICE_HANDLER( centronics_d1_w );
40WRITE_LINE_DEVICE_HANDLER( centronics_d2_w );
41WRITE_LINE_DEVICE_HANDLER( centronics_d3_w );
42WRITE_LINE_DEVICE_HANDLER( centronics_d4_w );
43WRITE_LINE_DEVICE_HANDLER( centronics_d5_w );
44WRITE_LINE_DEVICE_HANDLER( centronics_d6_w );
45WRITE_LINE_DEVICE_HANDLER( centronics_d7_w );
46 
5347WRITE_LINE_DEVICE_HANDLER( centronics_strobe_w );
5448WRITE_LINE_DEVICE_HANDLER( centronics_prime_w );
5549WRITE_LINE_DEVICE_HANDLER( centronics_init_w );
r4255r4256
6256READ_LINE_DEVICE_HANDLER( centronics_vcc_r );
6357READ_LINE_DEVICE_HANDLER( centronics_fault_r );
6458 
59/* callback for the printer device */
60void centronics_printer_online(const device_config *device, int state);
6561 
62 
6663/***************************************************************************
64    DEVICE CONFIGURATION MACROS
65***************************************************************************/
66 
67#define CENTRONICS DEVICE_GET_INFO_NAME(centronics)
68 
69#define MDRV_CENTRONICS_ADD(_tag, _intf) \
70   MDRV_PRINTER_ADD(_tag) \
71   MDRV_PRINTER_ONLINE(centronics_printer_online) \
72   MDRV_DEVICE_ADD(_tag, CENTRONICS, 0) \
73   MDRV_DEVICE_CONFIG(_intf)
74 
75#define MDRV_CENTRONICS_REMOVE(_tag) \
76   MDRV_PRINTER_REMOVE(_tag) \
77   MDRV_DEVICE_REMOVE(_tag, CENTRONICS)
78 
79 
80/***************************************************************************
6781    DEFAULT INTERFACES
6882***************************************************************************/
6983 
src/mess/devices/printer.c
r4255r4256
4141}
4242
4343
44/*-------------------------------------------------
45    DEVICE_IMAGE_LOAD( printer )
46-------------------------------------------------*/
4447
48static DEVICE_IMAGE_LOAD( printer )
49{
50   const printer_config *conf = image->inline_config;
51
52   /* send notify that the printer is now online */
53   if (conf != NULL && conf->online != NULL)
54      conf->online(image, TRUE);
55
56   /* we don't need to do anything special */
57   return INIT_PASS;
58}
59
60
4561/*-------------------------------------------------
62    DEVICE_IMAGE_UNLOAD( printer )
63-------------------------------------------------*/
64
65static DEVICE_IMAGE_UNLOAD( printer )
66{
67   const printer_config *conf = image->inline_config;
68
69   /* send notify that the printer is now offline */
70   if (conf != NULL && conf->online != NULL)
71      conf->online(image, FALSE);
72}
73
74
75/*-------------------------------------------------
4676    DEVICE_START(printer)
4777-------------------------------------------------*/
4878
r4255r4256
6292   {
6393      /* --- the following bits of info are returned as 64-bit signed integers --- */
6494      case DEVINFO_INT_TOKEN_BYTES:               info->i = 1; break;
65      case DEVINFO_INT_INLINE_CONFIG_BYTES:         info->i = 0; break;
95      case DEVINFO_INT_INLINE_CONFIG_BYTES:         info->i = sizeof(printer_config); break;
6696      case DEVINFO_INT_CLASS:                     info->i = DEVICE_CLASS_PERIPHERAL; break;
6797      case DEVINFO_INT_IMAGE_TYPE:               info->i = IO_PRINTER; break;
6898      case DEVINFO_INT_IMAGE_READABLE:            info->i = 0; break;
r4255r4256
71101
72102      /* --- the following bits of info are returned as pointers to data or functions --- */
73103      case DEVINFO_FCT_START:                     info->start = DEVICE_START_NAME(printer); break;
104      case DEVINFO_FCT_IMAGE_LOAD:               info->f = (genf *) DEVICE_IMAGE_LOAD_NAME(printer);      break;
105      case DEVINFO_FCT_IMAGE_UNLOAD:               info->f = (genf *) DEVICE_IMAGE_UNLOAD_NAME(printer);   break;
74106
75107      /* --- the following bits of info are returned as NULL-terminated strings --- */
76108      case DEVINFO_STR_NAME:                     strcpy(info->s, "Printer"); break;
src/mess/devices/printer.h
r4255r4256
1616    TYPE DEFINITIONS
1717***************************************************************************/
1818
19typedef void (*online_func)(const device_config *device, int state);
20
21typedef struct _printer_config printer_config;
22struct _printer_config
23{
24   online_func online;
25};
26
27
1928#define PRINTER   DEVICE_GET_INFO_NAME(printer)
2029
2130
2231#define MDRV_PRINTER_ADD(_tag) \
2332   MDRV_DEVICE_ADD(_tag, PRINTER, 0) \
2433
34#define MDRV_PRINTER_ONLINE(_online) \
35   MDRV_DEVICE_CONFIG_DATAPTR(printer_config, online, _online)
2536
37
2638/***************************************************************************
2739    FUNCTION PROTOTYPES
2840***************************************************************************/
src/mess/drivers/amstrad.c
r4255r4256
7878----------------
7979    - CRTC all type support (0,1,2,3,4) ?
8080    - Gate Array and CRTC aren't synchronised. (The Gate Array can change the color every microseconds?) So the multi-rasters in one line aren't supported (see yao demo p007's part)!
81    - Implement full Asic for CPC+ emulation.  Soft scroll is rather dodgy.  8-bit printer port (bit 3 of CRTC reg 12) not implemented.
81    - Implement full Asic for CPC+ emulation.  Soft scroll is rather dodgy.
8282   - The KC Compact should not reuse the gate array functionality. Instead z8536 support should be added. (bug #42)
8383
8484 ******************************************************************************/
r4255r4256
8888#include "includes/amstrad.h"
8989
9090/* Components */
91#include "machine/centroni.h"
9291#include "machine/8255ppi.h"   /* for 8255 ppi */
9392#include "cpu/z80/z80.h"      /* for cycle tables */
9493#include "video/mc6845.h"      /* CRTC */
r4255r4256
9695#include "sound/ay8910.h"
9796#include "sound/wave.h"
9897#include "machine/mc146818.h"  /* Aleste RTC */
98#include "machine/ctronics.h"
9999
100100/* Devices */
101101#include "devices/dsk.h"      /* for CPCEMU style disk images */
102102#include "devices/basicdsk.h"   /* for 720k MSX disk images (Aleste supports these) */
103#include "includes/msx_slot.h" 
103#include "includes/msx_slot.h"
104104#include "includes/msx.h"  /* MSX floppy device load */
105105#include "devices/snapquik.h"
106106#include "devices/cartslot.h"
r4255r4256
147147   aleste_interrupt,
148148   NULL,
149149   NULL,
150   NEC765_RDY_PIN_CONNECTED   
150   NEC765_RDY_PIN_CONNECTED
151151};
152152
153153
r4255r4256
541541   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\xC3\x96")            PORT_CODE(KEYCODE_COLON)       PORT_CHAR(0x00D6)
542542   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD)                                    PORT_CODE(KEYCODE_SLASH)      PORT_CHAR('<') PORT_CHAR('>')
543543   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD)                                    PORT_CODE(KEYCODE_STOP)       PORT_CHAR('.') PORT_CHAR(':')
544   
544
545545   PORT_MODIFY("keyboard_row_4")
546546   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD)                                    PORT_CODE(KEYCODE_COMMA)      PORT_CHAR(',') PORT_CHAR(';')
547547INPUT_PORTS_END
r4255r4256
550550 * The BIOS of the KC Compact would be able to recognize the keypresses
551551 * generated by F5-F9. Unfortunately these keys are not present on the
552552 * keyboard! Reference: http://www.cepece.info/amstrad/docs/kcc/kcc01.jpg
553 *
553 *
554554 */
555555static INPUT_PORTS_START( kccomp )
556556   PORT_INCLUDE(amstrad_keyboard)
r4255r4256
578578   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("f4")                    PORT_CODE(KEYCODE_4_PAD)      PORT_CHAR(UCHAR_MAMEKEY(4_PAD))
579579   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD)                                    PORT_CODE(KEYCODE_RCONTROL)   PORT_CHAR('\\') PORT_CHAR('`')
580580   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Control")               PORT_CODE(KEYCODE_LALT)       PORT_CHAR(UCHAR_SHIFT_2)
581   
581
582582   PORT_INCLUDE(crtc_links)
583583INPUT_PORTS_END
584584
r4255r4256
680680   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_BUTTON1)        PORT_PLAYER(2)
681681   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_BUTTON2)        PORT_PLAYER(2)
682682   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_UNUSED)
683   
683
684684   PORT_START("keyboard_row_7")
685685   PORT_BIT(0xff, IP_ACTIVE_LOW, IPT_UNUSED)
686686
r4255r4256
878878   MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25)
879879
880880   /* printer */
881   MDRV_PRINTER_ADD("printer")
881   MDRV_CENTRONICS_ADD("centronics", standard_centronics)
882882
883883   /* snapshot */
884884   MDRV_SNAPSHOT_ADD(amstrad, "sna", 0)
885885
886886   MDRV_CASSETTE_ADD( "cassette", amstrad_cassette_config )
887   
887
888888   MDRV_NEC765A_ADD("nec765", amstrad_nec765_interface)
889889MACHINE_DRIVER_END
890890
r4255r4256
934934   MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25)
935935
936936   /* printer */
937   MDRV_PRINTER_ADD("printer")
937   MDRV_CENTRONICS_ADD("centronics", standard_centronics)
938938
939939   /* snapshot */
940940   MDRV_SNAPSHOT_ADD(amstrad, "sna", 0)
941941
942942   MDRV_CASSETTE_ADD( "cassette", amstrad_cassette_config )
943   
943
944944   MDRV_NEC765A_ADD("nec765", amstrad_nec765_interface)
945   
945
946946   MDRV_IMPORT_FROM(cpcplus_cartslot)
947947MACHINE_DRIVER_END
948948
r4255r4256
11581158
11591159
11601160static SYSTEM_CONFIG_START( gx4000 )
1161   CONFIG_RAM_DEFAULT(64 * 1024)  // has 64k RAM   
1161   CONFIG_RAM_DEFAULT(64 * 1024)  // has 64k RAM
11621162SYSTEM_CONFIG_END
11631163
11641164
docs/messnew.txt
r4255r4256
1616
1717System Driver Changes:
1818----------------------
19
20- [AMSTRAD] Updated to use the new centronics interface, connected
21  data bit 8 for the CPC Plus machines.  [Dirk Best]
22
1923- [APPLE1] Fixed character layout.  [rhester72]
2024
2125- [ATOM] Rewrote printer interface.  [Dirk Best]

Previous 15994 Revisions Next


© 1998-2018 The MESS Team