Previous 15994 Revisions Next

r3759 Monday 8th December, 2008 at 00:13:06 UTC by R. Belmont
Fix up and enable SGI and PC shared stuff.
[src/mess]mess.mak
[src/mess/includes]europc.h ibmpc.h
[src/mess/machine]europc.c ibmpc.c pc.c pc_hdc.c pc_hdc.h pc_joy.c pc_turbo.c pc_turbo.h
[src/mess/video]crtc_ega.c pc_cga.c pc_mda.c pc_vga.c

src/mess/video/pc_vga.c
r3758r3759
668668         int clock=vga.monitor.get_clock();
669669         int lines=vga.monitor.get_lines();
670670         int columns=vga.monitor.get_columns();
671         int diff = (attotime_mul(attotime_sub(timer_get_time(machine), vga.monitor.start_time), clock).seconds)
671         int diff = (attotime_mul(attotime_sub(timer_get_time(space->machine), vga.monitor.start_time), clock).seconds)
672672            %(lines*columns);
673673         if (diff<columns*vga.monitor.get_sync_lines()) data|=8;
674674         diff=diff/lines;
r3758r3759
678678      if (vga.monitor.retrace)
679679      {
680680         data |= 1;
681         if (attotime_compare(attotime_sub(timer_get_time(machine), vga.monitor.start_time), ATTOTIME_IN_USEC(300)) > 0)
681         if (attotime_compare(attotime_sub(timer_get_time(space->machine), vga.monitor.start_time), ATTOTIME_IN_USEC(300)) > 0)
682682         {
683683            data |= 8;
684684            vga.monitor.retrace=0;
r3758r3759
686686      }
687687      else
688688      {
689         if (attotime_compare(attotime_sub(timer_get_time(machine), vga.monitor.start_time), ATTOTIME_IN_MSEC(15)) > 0)
689         if (attotime_compare(attotime_sub(timer_get_time(space->machine), vga.monitor.start_time), ATTOTIME_IN_MSEC(15)) > 0)
690690            vga.monitor.retrace=1;
691         vga.monitor.start_time=timer_get_time(machine);
691         vga.monitor.start_time=timer_get_time(space->machine);
692692      }
693693#else
694694      // not working with ps2m30
r3758r3759
943943         vga_cpu_interface(space->machine);
944944
945945         if (vga.sequencer.index == 0)
946            vga.monitor.start_time = timer_get_time(machine);
946            vga.monitor.start_time = timer_get_time(space->machine);
947947      }
948948      break;
949949   case 6:
src/mess/video/crtc_ega.c
r3758r3759
705705
706706      /* create the timers */
707707      if (crtc_ega->intf->on_de_changed != NULL)
708         crtc_ega->de_changed_timer = timer_alloc(machine, de_changed_timer_cb, (void *)device);
708         crtc_ega->de_changed_timer = timer_alloc(device->machine, de_changed_timer_cb, (void *)device);
709709
710710      if (crtc_ega->intf->on_hsync_changed != NULL)
711711      {
712         crtc_ega->hsync_on_timer = timer_alloc(machine, hsync_on_timer_cb, (void *)device);
713         crtc_ega->hsync_off_timer = timer_alloc(machine, hsync_off_timer_cb, (void *)device);
712         crtc_ega->hsync_on_timer = timer_alloc(device->machine, hsync_on_timer_cb, (void *)device);
713         crtc_ega->hsync_off_timer = timer_alloc(device->machine, hsync_off_timer_cb, (void *)device);
714714      }
715715
716716      if (crtc_ega->intf->on_vsync_changed != NULL)
717717      {
718         crtc_ega->vsync_on_timer = timer_alloc(machine, vsync_on_timer_cb, (void *)device);
719         crtc_ega->vsync_off_timer = timer_alloc(machine, vsync_off_timer_cb, (void *)device);
718         crtc_ega->vsync_on_timer = timer_alloc(device->machine, vsync_on_timer_cb, (void *)device);
719         crtc_ega->vsync_off_timer = timer_alloc(device->machine, vsync_off_timer_cb, (void *)device);
720720      }
721721   }
722722
723   crtc_ega->light_pen_latch_timer = timer_alloc(machine, light_pen_latch_timer_cb, (void *)device);
723   crtc_ega->light_pen_latch_timer = timer_alloc(device->machine, light_pen_latch_timer_cb, (void *)device);
724724
725725   /* register for state saving */
726726
727727   state_save_register_postload(device->machine, crtc_ega_state_save_postload, crtc_ega);
728728
729   state_save_register_item(device->tag, NULL, 0, crtc_ega->clock);
730   state_save_register_item(device->tag, NULL, 0, crtc_ega->hpixels_per_column);
731   state_save_register_item(device->tag, NULL, 0, crtc_ega->register_address_latch);
732   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_char_total);
733   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_disp);
734   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_blank_start);
735   state_save_register_item(device->tag, NULL, 0, crtc_ega->mode_control);
736   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_start_ras);
737   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_end_ras);
738   state_save_register_item(device->tag, NULL, 0, crtc_ega->disp_start_addr);
739   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_addr);
740   state_save_register_item(device->tag, NULL, 0, crtc_ega->light_pen_addr);
741   state_save_register_item(device->tag, NULL, 0, crtc_ega->light_pen_latched);
742   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_state);
743   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_blink_count);
744   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_blank_end);
745   state_save_register_item(device->tag, NULL, 0, crtc_ega->ena_vert_access);
746   state_save_register_item(device->tag, NULL, 0, crtc_ega->de_skew);
747   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_retr_start);
748   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_retr_end);
749   state_save_register_item(device->tag, NULL, 0, crtc_ega->horiz_retr_skew);
750   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_total);
751   state_save_register_item(device->tag, NULL, 0, crtc_ega->preset_row_scan);
752   state_save_register_item(device->tag, NULL, 0, crtc_ega->byte_panning);
753   state_save_register_item(device->tag, NULL, 0, crtc_ega->max_ras_addr);
754   state_save_register_item(device->tag, NULL, 0, crtc_ega->scan_doubling);
755   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_disable);
756   state_save_register_item(device->tag, NULL, 0, crtc_ega->cursor_skew);
757   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_retr_start);
758   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_retr_end);
759   state_save_register_item(device->tag, NULL, 0, crtc_ega->protect);
760   state_save_register_item(device->tag, NULL, 0, crtc_ega->bandwidth);
761   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_disp_end);
762   state_save_register_item(device->tag, NULL, 0, crtc_ega->offset);
763   state_save_register_item(device->tag, NULL, 0, crtc_ega->underline_loc);
764   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_blank_start);
765   state_save_register_item(device->tag, NULL, 0, crtc_ega->vert_blank_end);
766   state_save_register_item(device->tag, NULL, 0, crtc_ega->line_compare);
729   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->clock);
730   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->hpixels_per_column);
731   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->register_address_latch);
732   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_char_total);
733   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_disp);
734   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_blank_start);
735   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->mode_control);
736   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_start_ras);
737   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_end_ras);
738   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->disp_start_addr);
739   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_addr);
740   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->light_pen_addr);
741   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->light_pen_latched);
742   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_state);
743   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_blink_count);
744   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_blank_end);
745   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->ena_vert_access);
746   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->de_skew);
747   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_retr_start);
748   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_retr_end);
749   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->horiz_retr_skew);
750   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_total);
751   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->preset_row_scan);
752   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->byte_panning);
753   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->max_ras_addr);
754   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->scan_doubling);
755   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_disable);
756   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->cursor_skew);
757   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_retr_start);
758   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_retr_end);
759   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->protect);
760   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->bandwidth);
761   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_disp_end);
762   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->offset);
763   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->underline_loc);
764   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_blank_start);
765   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->vert_blank_end);
766   state_save_register_item(device->machine, device->tag, NULL, 0, crtc_ega->line_compare);
767767}
768768
769769
src/mess/video/pc_mda.c
r3758r3759
147147   UINT16   *p = BITMAP_ADDR16( bitmap, y, 0 );
148148   UINT16   chr_base = ( ra & 0x08 ) ? 0x800 | ( ra & 0x07 ) : ra;
149149   int i;
150   running_machine *machine = device->machine;
150151
151152   if ( y == 0 ) MDA_LOG(1,"mda_text_inten_update_row",("\n"));
152153   for ( i = 0; i < x_count; i++ )
r3758r3759
219220   UINT16   *p = BITMAP_ADDR16( bitmap, y, 0 );
220221   UINT16   chr_base = ( ra & 0x08 ) ? 0x800 | ( ra & 0x07 ) : ra;
221222   int i;
223   running_machine *machine = device->machine;
222224
223225   if ( y == 0 ) MDA_LOG(1,"mda_text_blink_update_row",("\n"));
224226   for ( i = 0; i < x_count; i++ )
r3758r3759
317319/*
318320 *   rW   MDA mode control register (see #P138)
319321 */
320static void mda_mode_control_w(int data)
322static void mda_mode_control_w(running_machine *machine, int data)
321323{
322324   MDA_LOG(1,"MDA_mode_control_w",("$%02x: colums %d, gfx %d, enable %d, blink %d\n",
323325      data, (data&1)?80:40, (data>>1)&1, (data>>3)&1, (data>>5)&1));
r3758r3759
373375         mc6845_register_w( devconf, offset, data );
374376         break;
375377      case 8:
376         mda_mode_control_w(data);
378         mda_mode_control_w(space->machine, data);
377379         break;
378380   }
379381}
r3758r3759
490492   UINT16   *p = BITMAP_ADDR16( bitmap, y, 0 );
491493   UINT16   gfx_base = ( ( mda.mode_control & 0x80 ) ? 0x8000 : 0x0000 ) | ( ( ra & 0x03 ) << 13 );
492494   int i;
495   running_machine *machine = device->machine;
493496
494497   if ( y == 0 ) MDA_LOG(1,"hercules_gfx_update_row",("\n"));
495498   for ( i = 0; i < x_count; i++ )
r3758r3759
556559}
557560
558561
559static void hercules_config_w(int data)
562static void hercules_config_w(running_machine *machine, int data)
560563{
561564   MDA_LOG(1,"HGC_config_w",("$%02x\n", data));
562565   mda.configuration_switch = data;
r3758r3759
579582      hercules_mode_control_w(space->machine, data);
580583      break;
581584   case 15:
582      hercules_config_w(data);
585      hercules_config_w(space->machine, data);
583586      break;
584587   }
585588}
src/mess/video/pc_cga.c
r3758r3759
546546{
547547   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
548548   int i;
549   running_machine *machine = device->machine;
549550
550551   if ( y == 0 ) CGA_LOG(1,"cga_text_inten_update_row",("\n"));
551552   for ( i = 0; i < x_count; i++ )
r3758r3759
583584{
584585   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
585586   int i;
587   running_machine *machine = device->machine;
586588
587589   if ( y == 0 ) CGA_LOG(1,"cga_text_inten_update_row",("\n"));
588590   for ( i = 0; i < x_count; i++ )
r3758r3759
619621{
620622   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
621623   int i;
624   running_machine *machine = device->machine;
622625
623626   if ( y == 0 ) CGA_LOG(1,"cga_text_inten_alt_update_row",("\n"));
624627   for ( i = 0; i < x_count; i++ )
r3758r3759
655658{
656659   UINT16   *p = BITMAP_ADDR16(bitmap, y, 0);
657660   int i;
661   running_machine *machine = device->machine;
658662
659663   if ( y == 0 ) CGA_LOG(1,"cga_text_blink_update_row",("\n"));
660664   for ( i = 0; i < x_count; i++ )
r3758r3759
702706{
703707   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
704708   int i;
709   running_machine *machine = device->machine;
705710
706711   if ( y == 0 ) CGA_LOG(1,"cga_text_blink_alt_update_row",("\n"));
707712   for ( i = 0; i < x_count; i++ )
r3758r3759
747752{
748753   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
749754   int i;
755   running_machine *machine = device->machine;
750756
751757   if ( y == 0 ) CGA_LOG(1,"cga_gfx_4bppl_update_row",("\n"));
752758   for ( i = 0; i < x_count; i++ )
r3758r3759
805811   int      samp_index = 0;
806812   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
807813   int i;
814   running_machine *machine = device->machine;
808815
809816   if ( y == 0 ) CGA_LOG(1,"cga_gfx_4bpph_update_row",("\n"));
810817if ( NTSC_FILTER )
r3758r3759
907914{
908915   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
909916   int i;
917   running_machine *machine = device->machine;
910918
911919   if ( y == 0 ) CGA_LOG(1,"cga_gfx_2bpp_update_row",("\n"));
912920   for ( i = 0; i < x_count; i++ )
r3758r3759
941949   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
942950   UINT8   fg = cga.color_select & 0x0F;
943951   int i;
952   running_machine *machine = device->machine;
944953
945954   if ( y == 0 ) CGA_LOG(1,"cga_gfx_1bpp_update_row",("\n"));
946955   for ( i = 0; i < x_count; i++ )
r3758r3759
11561165/*
11571166 *   ?W   reserved for color select register on color adapter
11581167 */
1159static void pc_cga_color_select_w(int data)
1168static void pc_cga_color_select_w(running_machine *machine, int data)
11601169{
11611170   CGA_LOG(1,"CGA_color_select_w",("$%02x\n", data));
11621171   cga.color_select = data;
r3758r3759
11691178/*
11701179 * Select Plantronics modes
11711180 */
1172static void pc_cga_plantronics_w(int data)
1181static void pc_cga_plantronics_w(running_machine *machine, int data)
11731182{
11741183   CGA_LOG(1,"CGA_plantronics_w",("$%02x\n", data));
11751184
r3758r3759
12271236      pc_cga_mode_control_w(space->machine, data);
12281237      break;
12291238   case 9:
1230      pc_cga_color_select_w(data);
1239      pc_cga_color_select_w(space->machine, data);
12311240      break;
12321241   case 0x0d:
1233      pc_cga_plantronics_w(data);
1242      pc_cga_plantronics_w(space->machine, data);
12341243      break;
12351244   }
12361245}
r3758r3759
14571466   UINT16  *p = BITMAP_ADDR16(bitmap, y, 0);
14581467   UINT16   offset_base = ra << 13;
14591468   int i;
1469   running_machine *machine = device->machine;
14601470
14611471   if ( y == 0 ) CGA_LOG(1,"pc1512_gfx_4bpp_update_row",("\n"));
14621472   for ( i = 0; i < x_count; i++ )
src/mess/includes/europc.h
r3758r3759
146146extern NVRAM_HANDLER( europc_rtc );
147147
148148void europc_rtc_set_time(running_machine *machine);
149void europc_rtc_init(void);
149void europc_rtc_init(running_machine *machine);
150150
151151
152152#endif /* EUROPC_H_ */
src/mess/includes/ibmpc.h
r3758r3759
1616READ16_HANDLER( pc16le_rtc_r );
1717WRITE16_HANDLER( pc16le_rtc_w );
1818
19void pc_rtc_init(void);
19void pc_rtc_init(running_machine *machine);
2020
2121READ8_HANDLER ( pc_EXP_r );
2222WRITE8_HANDLER ( pc_EXP_w );
src/mess/machine/europc.c
r3758r3759
273273   }
274274}
275275
276void europc_rtc_init(void)
276void europc_rtc_init(running_machine *machine)
277277{
278278   memset(&europc_rtc,0,sizeof(europc_rtc));
279279   europc_rtc.data[0xf]=1;
src/mess/machine/pc_hdc.c
r3758r3759
178178
179179static TIMER_CALLBACK(pc_hdc_command);
180180
181int pc_hdc_setup(void (*hdc_set_irq_func)(int,int))
181int pc_hdc_setup(running_machine *machine, void (*hdc_set_irq_func)(int,int))
182182{
183183   int i;
184184
src/mess/machine/pc_hdc.h
r3758r3759
33
44#include "driver.h"
55
6int pc_hdc_setup(void (*hdc_set_irq_func)(int,int));
6int pc_hdc_setup(running_machine *machine, void (*hdc_set_irq_func)(int,int));
77
88READ8_HANDLER  ( pc_HDC1_r );
99WRITE8_HANDLER ( pc_HDC1_w );
src/mess/machine/pc_joy.c
r3758r3759
1818{
1919   UINT8 data = 0;
2020   int delta;
21   attotime new_time = timer_get_time(machine);
21   attotime new_time = timer_get_time(space->machine);
2222   const input_port_config *joystick_port = input_port_by_tag(space->machine->portconfig, "pc_joy");
2323
2424   if (joystick_port != NULL)
r3758r3759
4646
4747WRITE8_HANDLER ( pc_JOY_w )
4848{
49   JOY_time = timer_get_time(machine);
49   JOY_time = timer_get_time(space->machine);
5050}
5151
5252
src/mess/machine/pc_turbo.c
r3758r3759
3838
3939
4040
41int pc_turbo_setup(int cpunum, const char *port, int mask, double off_speed, double on_speed)
41int pc_turbo_setup(running_machine *machine, int cpunum, const char *port, int mask, double off_speed, double on_speed)
4242{
4343   struct pc_turbo_info *ti;
4444
src/mess/machine/pc_turbo.h
r3758r3759
99#ifndef PC_TURBO_H
1010#define PC_TURBO_H
1111
12int pc_turbo_setup(int cpunum, const char *port, int mask, double off_speed, double on_speed);
12int pc_turbo_setup(running_machine *machine, int cpunum, const char *port, int mask, double off_speed, double on_speed);
1313
1414
1515#endif /* PC_TURBO_H */
src/mess/machine/ibmpc.c
r3758r3759
109109   }
110110}
111111
112void pc_rtc_init(void)
112void pc_rtc_init(running_machine *machine)
113113{
114114   memset(&pc_rtc,0,sizeof(pc_rtc));
115115   pc_rtc.timer = timer_alloc(machine, pc_rtc_timer, NULL);
r3758r3759
160160
161161WRITE8_HANDLER ( pc_EXP_w )
162162{
163   running_machine *machine = space->machine;
164
163165   DBG_LOG(1,"EXP_unit_w",("%.2x $%02x\n", offset, data));
164166   switch (offset) {
165167   case 4:
r3758r3759
174176{
175177    int data;
176178   UINT16 a;
179   running_machine *machine = space->machine;
177180
178181   switch (offset) {
179182   case 6:
src/mess/machine/pc.c
r3758r3759
229229{
230230   if ( cpu_get_reg( device->machine->cpu[0], REG_PC ) == 0xF0454 )
231231   {
232      timer_adjust_oneshot( pc_int_delay_timer, cpu_clocks_to_attotime(machine->cpu[0], 1), interrupt );
232      timer_adjust_oneshot( pc_int_delay_timer, cpu_clocks_to_attotime(device->machine->cpu[0], 1), interrupt );
233233   }
234234   else
235235   {
r3758r3759
574574}
575575
576576
577static void pcjr_keyb_init(void)
577static void pcjr_keyb_init(running_machine *machine)
578578{
579579   pcjr_keyb.transferring = 0;
580580   pcjr_keyb.latch = 0;
r3758r3759
660660static READ8_DEVICE_HANDLER (ibm5150_ppi_porta_r)
661661{
662662   int data = 0xFF;
663   running_machine *machine = device->machine;
663664
664665   /* KB port A */
665666   if (pc_ppi.keyboard_clear)
r3758r3759
702703static READ8_DEVICE_HANDLER (ibm5150_ppi_portb_r )
703704{
704705   int data;
706   running_machine *machine = device->machine;
705707
706708   data = 0xff;
707709   PIO_LOG(1,"PIO_B_r",("$%02x\n", data));
r3758r3759
713715{
714716   int timer2_output = pit8253_get_output( pc_devices.pit8253, 2 );
715717   int data=0xff;
718   running_machine *machine = device->machine;
716719
717720   data&=~0x80; // no parity error
718721   data&=~0x40; // no error on expansion board
r3758r3759
780783
781784static WRITE8_DEVICE_HANDLER ( ibm5150_ppi_porta_w )
782785{
786   running_machine *machine = device->machine;
787
783788   /* KB controller port A */
784789   PIO_LOG(1,"PIO_A_w",("$%02x\n", data));
785790}
r3758r3759
790795   /* KB controller port B */
791796   pc_ppi.portb = data;
792797   pc_ppi.portc_switch_high = data & 0x08;
793   pc_ppi.keyboard_clear = data & 0x80;
798      pc_ppi.keyboard_clear = data & 0x80;
794799   pc_ppi.keyb_clock = data & 0x40;
795800   pit8253_gate_w( pc_devices.pit8253, 2, data & 1);
796801   pc_speaker_set_spkrdata( data & 0x02 );
r3758r3759
813818
814819static WRITE8_DEVICE_HANDLER ( ibm5150_ppi_portc_w )
815820{
821   running_machine *machine = device->machine;
822
816823   /* KB controller port C */
817824   PIO_LOG(1,"PIO_C_w",("$%02x\n", data));
818825}
r3758r3759
880887static READ8_DEVICE_HANDLER (ibm5160_ppi_porta_r)
881888{
882889   int data = 0xFF;
890   running_machine *machine = device->machine;
883891
884892   /* KB port A */
885893   if (pc_ppi.keyboard_clear)
r3758r3759
911919{
912920   int timer2_output = pit8253_get_output( pc_devices.pit8253, 2 );
913921   int data=0xff;
922   running_machine *machine = device->machine;
914923
915924   data&=~0x80; // no parity error
916925   data&=~0x40; // no error on expansion board
r3758r3759
983992static READ8_DEVICE_HANDLER (pcjr_ppi_porta_r )
984993{
985994   int data;
995   running_machine *machine = device->machine;
986996
987997   data = 0xff;
988998   PIO_LOG(1,"PIO_A_r",("$%02x\n", data));
r3758r3759
11201130DRIVER_INIT( ibm5150 )
11211131{
11221132   mess_init_pc_common(machine, PCCOMMON_KEYBOARD_PC, pc_set_keyb_int, pc_set_irq_line);
1123   pc_rtc_init();
1133   pc_rtc_init(machine);
11241134
11251135   /* Attach keyboard to the keyboard controller */
11261136   ibm5150_set_keyboard_interface( machine, kb_keytronic_set_clock_signal, kb_keytronic_set_data_signal );
r3758r3759
11311141DRIVER_INIT( pccga )
11321142{
11331143   mess_init_pc_common(machine, PCCOMMON_KEYBOARD_PC, pc_set_keyb_int, pc_set_irq_line);
1134   pc_rtc_init();
1144   pc_rtc_init(machine);
11351145}
11361146
11371147
r3758r3759
11691179
11701180   mess_init_pc_common(machine, PCCOMMON_KEYBOARD_PC, pc_set_keyb_int, pc_set_irq_line);
11711181
1172   europc_rtc_init();
1182   europc_rtc_init(machine);
11731183//   europc_rtc_set_time(machine);
11741184}
11751185
r3758r3759
13331343MACHINE_RESET( pcjr )
13341344{
13351345   MACHINE_RESET_CALL( pc );
1336   pcjr_keyb_init();
1346   pcjr_keyb_init(machine);
13371347   pc_int_delay_timer = timer_alloc(machine,  pcjr_delayed_pic8259_irq, NULL );
13381348}
13391349
src/mess/mess.mak
r3758r3759
421421   $(MESSOBJ)/mikro80.a \
422422   $(MESSOBJ)/ondra.a \
423423   $(MESSOBJ)/orion.a \
424   $(MESSOBJ)/pc.a \
425   $(MESSOBJ)/pcshare.a \
424426   $(MESSOBJ)/pel.a \
425427   $(MESSOBJ)/pk8020.a \
426428   $(MESSOBJ)/pmd85.a \
r3758r3759
429431   $(MESSOBJ)/radio.a \
430432   $(MESSOBJ)/rt1715.a \
431433   $(MESSOBJ)/sapi1.a \
434   $(MESSOBJ)/sgi.a \
432435   $(MESSOBJ)/sharp.a \
433436   $(MESSOBJ)/special.a \
434437   $(MESSOBJ)/sony.a \
r3758r3759
475478#   $(MESSOBJ)/osborne.a \
476479#   $(MESSOBJ)/p2000.a \
477480#   $(MESSOBJ)/pasogo.a \
478#   $(MESSOBJ)/pc.a \
479#   $(MESSOBJ)/pcshare.a \
480481#   $(MESSOBJ)/pdp1.a \
481482#   $(MESSOBJ)/rca.a \
482483#   $(MESSOBJ)/rockwell.a \
483484#   $(MESSOBJ)/samcoupe.a \
484485#   $(MESSOBJ)/sega.a \
485#   $(MESSOBJ)/sgi.a \
486486#   $(MESSOBJ)/sinclair.a \
487487#   $(MESSOBJ)/thomson.a \
488488#   $(MESSOBJ)/ti99.a \

Previous 15994 Revisions Next


© 1998-2018 The MESS Team