Previous 15994 Revisions Next

r5026 Monday 15th June, 2009 at 12:53:13 UTC by Curt Coder
[PROF80] Added FLASH attribute.
[src/mess/drivers]prof80.c
[src/mess/includes]prof80.h

src/mess/includes/prof80.h
r5025r5026
3232   UINT8 *video_ram;      /* video RAM */
3333   int lps;            /* light pen sense */
3434   int page;            /* video page */
35   int flash;            /* flash */
3536
3637   /* clock state */
3738   int rtc_data;         /* RTC data output */
src/mess/drivers/prof80.c
r5025r5026
1313
1414   TODO:
1515
16   - the characters are drawn to screen during vsync in a background process, which is controlled by 2 interrupts (CUR and DE)
17
18      'grip_z1' (00001162):M6845 reg 0x0e = 0x0d
19      'grip_z1' (00001162):M6845 reg 0x0f = 0x1f   --> cursor address 0xd1f, total characters (96x50) 0xd20
20
21      MC6845 CUR 0->1 on the last character of screen -> STI I2 interrupt (turns off display, enables DE int)
22      MC6845 DE 0->1 on the first character of screen -> STI I1 interrupt (turns on display, enabled CUR int)
23
16   - grip31 does not work
17   - write all 0 to flr_w on reset
2418   - PROF-80 RAM banking
2519   - PROF-80 floppy access
20   - GRIP model selection
2621   - UNIO card (Z80-STI, Z80-SIO, 2x centronics)
2722   - GRIP-COLOR (192kB color RAM)
28   - GRIP selection
2923   - GRIP-5 (HD6345, 256KB RAM)
3024   - XR color card
3125   
r5025r5026
282276{
283277   prof80_state *state = space->machine->driver_data;
284278
285   logerror("Read GRIP data %02x\n", state->ecb_data);
286
287279   /* trigger GRIP 8255 port C bit 6 (_ACKA) */
288280   ppi8255_set_port_c(state->ppi8255, 0x54);
289281   ppi8255_set_port_c(state->ppi8255, 0x14);
290282   ppi8255_set_port_c(state->ppi8255, 0x54);
291283
292   logerror("Read GRIP data %02x\n", state->ecb_data);
293
294284   return state->ecb_data;
295285}
296286
r5025r5026
298288{
299289   prof80_state *state = space->machine->driver_data;
300290
301   logerror("Write GRIP data %02x\n", data);
302
303291   state->ecb_data = data;
304292
305293   /* trigger GRIP 8255 port C bit 4 (_STBA) */
r5025r5026
310298
311299/* GRIP */
312300
301static WRITE8_HANDLER( flash_w )
302{
303   prof80_state *state = space->machine->driver_data;
304
305   state->flash = BIT(data, 7);
306}
307
313308static WRITE8_HANDLER( page_w )
314309{
315310   prof80_state *state = space->machine->driver_data;
r5025r5026
451446   AM_RANGE(0x13, 0x13) AM_WRITE(page_w)
452447//   AM_RANGE(0x14, 0x14) AM_WRITE(cc1_w)
453448//   AM_RANGE(0x15, 0x15) AM_WRITE(cc2_w)
454//   AM_RANGE(0x16, 0x16) AM_WRITE(flash_w)
449   AM_RANGE(0x16, 0x16) AM_WRITE(flash_w)
455450//   AM_RANGE(0x17, 0x17) AM_WRITE(vol1_w)
456451   AM_RANGE(0x20, 0x2f) AM_DEVREADWRITE(Z80STI_TAG, z80sti_r, z80sti_w)
457452   AM_RANGE(0x30, 0x30) AM_READWRITE(lrs_r, lrs_w)
r5025r5026
533528      for (bit = 0; bit < 8; bit++)
534529      {
535530         int x = (column * 8) + bit;
536         *BITMAP_ADDR16(bitmap, y, x) = BIT(data, bit);
531         int color = state->flash ? 0 : BIT(data, bit);
532
533         *BITMAP_ADDR16(bitmap, y, x) = color;
537534      }
538535   }
539536}
r5025r5026
654651
655652   prof80_state *state = device->machine->driver_data;
656653
657   logerror("8255 PA write %02x\n", data);
658
659654   state->ecb_data = data;
660655}
661656
r5025r5026
726721
727722   /* PROF-80 handshaking */
728723   state->ecb_status = (!BIT(data, 7) << 7) | (!BIT(data, 5) << 6);
729
730   logerror("8255 PC write %02x\n", data);
731724}
732725
733726static const ppi8255_interface grip_ppi8255_interface =

Previous 15994 Revisions Next


© 1998-2018 The MESS Team