trunk/src/lib/formats/mbee_dsk.c
| r0 | r24083 | |
| 1 | /*************************************************************************** |
| 2 | |
| 3 | Copyright Olivier Galibert |
| 4 | All rights reserved. |
| 5 | |
| 6 | Redistribution and use in source and binary forms, with or without |
| 7 | modification, are permitted provided that the following conditions are |
| 8 | met: |
| 9 | |
| 10 | * Redistributions of source code must retain the above copyright |
| 11 | notice, this list of conditions and the following disclaimer. |
| 12 | * Redistributions in binary form must reproduce the above copyright |
| 13 | notice, this list of conditions and the following disclaimer in |
| 14 | the documentation and/or other materials provided with the |
| 15 | distribution. |
| 16 | * Neither the name 'MAME' nor the names of its contributors may be |
| 17 | used to endorse or promote products derived from this software |
| 18 | without specific prior written permission. |
| 19 | |
| 20 | THIS SOFTWARE IS PROVIDED BY AARON GILES ''AS IS'' AND ANY EXPRESS OR |
| 21 | IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
| 22 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
| 23 | DISCLAIMED. IN NO EVENT SHALL AARON GILES BE LIABLE FOR ANY DIRECT, |
| 24 | INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
| 25 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
| 26 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) |
| 27 | HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, |
| 28 | STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING |
| 29 | IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
| 30 | POSSIBILITY OF SUCH DAMAGE. |
| 31 | |
| 32 | ****************************************************************************/ |
| 33 | |
| 34 | /********************************************************************* |
| 35 | |
| 36 | formats/mbee_dsk.c |
| 37 | |
| 38 | Microbee disk image format |
| 39 | |
| 40 | *********************************************************************/ |
| 41 | |
| 42 | #include "emu.h" |
| 43 | #include "formats/mbee_dsk.h" |
| 44 | |
| 45 | mbee_format::mbee_format() : wd177x_format(formats) |
| 46 | { |
| 47 | } |
| 48 | |
| 49 | const char *mbee_format::name() const |
| 50 | { |
| 51 | return "mbee"; |
| 52 | } |
| 53 | |
| 54 | const char *mbee_format::description() const |
| 55 | { |
| 56 | return "Microbee disk image"; |
| 57 | } |
| 58 | |
| 59 | const char *mbee_format::extensions() const |
| 60 | { |
| 61 | return "ss80,ds40,ds80,ds82,ds84"; |
| 62 | } |
| 63 | |
| 64 | // Unverified gap sizes |
| 65 | const mbee_format::format mbee_format::formats[] = { |
| 66 | { /* ss80 3 1/2 inch double density */ |
| 67 | floppy_image::FF_35, floppy_image::SSDD, floppy_image::MFM, |
| 68 | 1500, 10, 80, 1, 512, {}, 1, {}, 100, 22, 84 |
| 69 | }, |
| 70 | { /* ds40 5.25 inch double density */ |
| 71 | floppy_image::FF_525, floppy_image::DSDD, floppy_image::MFM, |
| 72 | 1500, 10, 40, 2, 512, {}, 1, {}, 100, 22, 84 |
| 73 | }, |
| 74 | { /* ds80 3 1/2 inch double density */ |
| 75 | floppy_image::FF_35, floppy_image::DSDD, floppy_image::MFM, |
| 76 | 1500, 10, 80, 2, 512, {}, 21, {}, 100, 22, 84 |
| 77 | }, |
| 78 | { /* ds82,ds84 3 1/2 inch double density */ |
| 79 | floppy_image::FF_35, floppy_image::DSDD, floppy_image::MFM, |
| 80 | 1500, 10, 80, 2, 512, {}, 1, {}, 100, 22, 84 |
| 81 | }, |
| 82 | {} |
| 83 | }; |
| 84 | |
| 85 | const floppy_format_type FLOPPY_MBEE_FORMAT = &floppy_image_format_creator<mbee_format>; |
trunk/src/mess/drivers/mbee.c
| r24082 | r24083 | |
| 82 | 82 | - The Monitor program on 256TC crashes the system. This appears |
| 83 | 83 | to be a MAME core bug involving the z80pio. |
| 84 | 84 | |
| 85 | - The 256TC corrupts itself when a floppy disk is detected. |
| 86 | |
| 85 | 87 | - Disk system doesn't work because of fdc problems. |
| 86 | 88 | |
| 87 | 89 | - Teleterm: keyboard is problematic, and cursor doesn't show. |
| 88 | 90 | |
| 89 | 91 | |
| 90 | | ***************************************************************************/ |
| 92 | *************************************************************************** |
| 91 | 93 | |
| 92 | | #include "emu.h" |
| 94 | Description of Disk System |
| 95 | |
| 96 | - Ports 44 to 47 are for standard connection to FD2793. |
| 97 | - Port 48 is used for drive/side/density select on write, |
| 98 | and intrq/drq on read. |
| 99 | intrq and drq are OR'd together, then gated to bit 7 of the |
| 100 | data bus whenever port 48 is activated on read. There are |
| 101 | no interrupts used in the disk system. |
| 102 | |
| 103 | Despite the simplicity of this design, disks have not worked |
| 104 | in the emulator for some years. Conversion to the new modern |
| 105 | implementation (2013-07-05) has not resolved the issue. |
| 106 | |
| 107 | There are 3 types of microbee disks available in the wild. |
| 108 | |
| 109 | - CPCEMU-format "dsk" disks, which has an already-working |
| 110 | format "dsk_dsk". |
| 111 | |
| 112 | - ubee512-format disks, such as "ds80,ds82,ds84,ss80", etc. |
| 113 | These are described in "mbee_dsk", but it's not known if it |
| 114 | works as yet. |
| 115 | |
| 116 | - There a "img" format for the 128k boot disk. The internal |
| 117 | layout is not known and no work has been done. |
| 118 | |
| 119 | |
| 120 | ****************************************************************************/ |
| 121 | |
| 122 | |
| 93 | 123 | #include "includes/mbee.h" |
| 124 | #include "formats/dsk_dsk.h" |
| 125 | #include "formats/mbee_dsk.h" |
| 94 | 126 | |
| 127 | |
| 95 | 128 | #define XTAL_13_5MHz 13500000 |
| 96 | 129 | |
| 97 | 130 | /********** NOTE !!! *********************************************************** |
| r24082 | r24083 | |
| 251 | 284 | AM_RANGE(0x0b, 0x0b) AM_MIRROR(0x10) AM_READWRITE(mbee_0b_r, mbee_0b_w) |
| 252 | 285 | AM_RANGE(0x0c, 0x0c) AM_MIRROR(0x10) AM_READWRITE(m6545_status_r, m6545_index_w) |
| 253 | 286 | AM_RANGE(0x0d, 0x0d) AM_MIRROR(0x10) AM_READWRITE(m6545_data_r, m6545_data_w) |
| 254 | | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE_LEGACY("fdc", wd17xx_r, wd17xx_w) |
| 287 | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE("fdc", wd2793_t, read, write) |
| 255 | 288 | AM_RANGE(0x48, 0x4f) AM_READWRITE(mbee_fdc_status_r, mbee_fdc_motor_w) |
| 256 | 289 | ADDRESS_MAP_END |
| 257 | 290 | |
| r24082 | r24083 | |
| 263 | 296 | AM_RANGE(0x0b, 0x0b) AM_MIRROR(0x10) AM_READWRITE(mbee_0b_r, mbee_0b_w) |
| 264 | 297 | AM_RANGE(0x0c, 0x0c) AM_MIRROR(0x10) AM_READWRITE(m6545_status_r, m6545_index_w) |
| 265 | 298 | AM_RANGE(0x0d, 0x0d) AM_MIRROR(0x10) AM_READWRITE(m6545_data_r, m6545_data_w) |
| 266 | | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE_LEGACY("fdc", wd17xx_r, wd17xx_w) |
| 299 | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE("fdc", wd2793_t, read, write) |
| 267 | 300 | AM_RANGE(0x48, 0x4f) AM_READWRITE(mbee_fdc_status_r, mbee_fdc_motor_w) |
| 268 | 301 | AM_RANGE(0x50, 0x57) AM_WRITE(mbee64_50_w) |
| 269 | 302 | ADDRESS_MAP_END |
| r24082 | r24083 | |
| 277 | 310 | AM_RANGE(0x0c, 0x0c) AM_READWRITE(m6545_status_r, m6545_index_w) |
| 278 | 311 | AM_RANGE(0x0d, 0x0d) AM_READWRITE(m6545_data_r, m6545_data_w) |
| 279 | 312 | AM_RANGE(0x1c, 0x1f) AM_READWRITE(mbeeppc_1c_r,mbee256_1c_w) |
| 280 | | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE_LEGACY("fdc", wd17xx_r, wd17xx_w) |
| 313 | AM_RANGE(0x44, 0x47) AM_DEVREADWRITE("fdc", wd2793_t, read, write) |
| 281 | 314 | AM_RANGE(0x48, 0x4f) AM_READWRITE(mbee_fdc_status_r, mbee_fdc_motor_w) |
| 282 | 315 | AM_RANGE(0x50, 0x57) AM_WRITE(mbee128_50_w) |
| 283 | 316 | ADDRESS_MAP_END |
| r24082 | r24083 | |
| 297 | 330 | // AM_RANGE(0x0010, 0x0013) AM_MIRROR(0xff00) Optional SN76489AN audio chip |
| 298 | 331 | AM_RANGE(0x0018, 0x001b) AM_MIRROR(0xff00) AM_READ(mbee256_18_r) |
| 299 | 332 | AM_RANGE(0x001c, 0x001f) AM_MIRROR(0xff00) AM_READWRITE(mbeeppc_1c_r,mbee256_1c_w) |
| 300 | | AM_RANGE(0x0044, 0x0047) AM_MIRROR(0xff00) AM_DEVREADWRITE_LEGACY("fdc", wd17xx_r, wd17xx_w) |
| 333 | AM_RANGE(0x0044, 0x0047) AM_MIRROR(0xff00) AM_DEVREADWRITE("fdc", wd2793_t, read, write) |
| 301 | 334 | AM_RANGE(0x0048, 0x004f) AM_MIRROR(0xff00) AM_READWRITE(mbee_fdc_status_r, mbee_fdc_motor_w) |
| 302 | 335 | AM_RANGE(0x0050, 0x0057) AM_MIRROR(0xff00) AM_WRITE(mbee256_50_w) |
| 303 | 336 | // AM_RANGE(0x0058, 0x005f) AM_MIRROR(0xff00) External options: floppy drive, hard drive and keyboard |
| r24082 | r24083 | |
| 572 | 605 | static GFXDECODE_START( mbeeppc ) |
| 573 | 606 | GFXDECODE_ENTRY( "gfx", 0x0000, mbee_charlayout, 0, 8 ) |
| 574 | 607 | GFXDECODE_END |
| 575 | | |
| 608 | #if 0 |
| 576 | 609 | static LEGACY_FLOPPY_OPTIONS_START(mbee) |
| 577 | 610 | LEGACY_FLOPPY_OPTION(ss80, "ss80", "SS80 disk image", basicdsk_identify_default, basicdsk_construct_default, NULL, |
| 578 | 611 | HEADS([1]) |
| r24082 | r24083 | |
| 612 | 645 | NULL, |
| 613 | 646 | NULL |
| 614 | 647 | }; |
| 648 | #endif |
| 615 | 649 | |
| 650 | // can only specify one |
| 651 | FLOPPY_FORMATS_MEMBER( mbee_state::floppy_formats ) |
| 652 | FLOPPY_MBEE_FORMAT, |
| 653 | FLOPPY_DSK_FORMAT |
| 654 | FLOPPY_FORMATS_END |
| 616 | 655 | |
| 656 | static SLOT_INTERFACE_START( mbee_floppies ) |
| 657 | SLOT_INTERFACE( "35dd", FLOPPY_35_DD ) |
| 658 | SLOT_INTERFACE_END |
| 659 | |
| 660 | |
| 617 | 661 | static MC6845_INTERFACE( mbee_crtc ) |
| 618 | 662 | { |
| 619 | 663 | "screen", /* name of screen */ |
| r24082 | r24083 | |
| 788 | 832 | MCFG_CPU_PROGRAM_MAP(mbee56_mem) |
| 789 | 833 | MCFG_CPU_IO_MAP(mbee56_io) |
| 790 | 834 | MCFG_MACHINE_RESET_OVERRIDE(mbee_state, mbee56 ) |
| 791 | | MCFG_WD2793_ADD("fdc", mbee_wd17xx_interface ) |
| 792 | | MCFG_LEGACY_FLOPPY_2_DRIVES_ADD(mbee_floppy_interface) |
| 835 | MCFG_WD2793x_ADD("fdc", XTAL_4MHz / 2) |
| 836 | MCFG_FLOPPY_DRIVE_ADD("fdc:0", mbee_floppies, "35dd", mbee_state::floppy_formats) |
| 837 | MCFG_FLOPPY_DRIVE_ADD("fdc:1", mbee_floppies, "35dd", mbee_state::floppy_formats) |
| 793 | 838 | MACHINE_CONFIG_END |
| 794 | 839 | |
| 795 | 840 | static MACHINE_CONFIG_DERIVED( mbee64, mbee56 ) |
| r24082 | r24083 | |
| 804 | 849 | MCFG_CPU_PROGRAM_MAP(mbee128_mem) |
| 805 | 850 | MCFG_CPU_IO_MAP(mbee128_io) |
| 806 | 851 | MCFG_MACHINE_RESET_OVERRIDE(mbee_state, mbee128 ) |
| 807 | | MCFG_WD2793_ADD("fdc", mbee_wd17xx_interface ) |
| 808 | | MCFG_LEGACY_FLOPPY_2_DRIVES_ADD(mbee_floppy_interface) |
| 852 | MCFG_WD2793x_ADD("fdc", XTAL_4MHz / 2) |
| 853 | MCFG_FLOPPY_DRIVE_ADD("fdc:0", mbee_floppies, "35dd", mbee_state::floppy_formats) |
| 854 | MCFG_FLOPPY_DRIVE_ADD("fdc:1", mbee_floppies, "35dd", mbee_state::floppy_formats) |
| 809 | 855 | MACHINE_CONFIG_END |
| 810 | 856 | |
| 811 | 857 | static MACHINE_CONFIG_DERIVED( mbee256, mbee128 ) |
trunk/src/mess/machine/mbee.c
| r24082 | r24083 | |
| 8 | 8 | |
| 9 | 9 | ****************************************************************************/ |
| 10 | 10 | |
| 11 | | #include "emu.h" |
| 12 | 11 | #include "includes/mbee.h" |
| 13 | 12 | #include "machine/z80bin.h" |
| 14 | 13 | |
| r24082 | r24083 | |
| 101 | 100 | |
| 102 | 101 | *************************************************************************************/ |
| 103 | 102 | |
| 104 | | WRITE_LINE_MEMBER( mbee_state::mbee_fdc_intrq_w ) |
| 103 | void mbee_state::fdc_intrq_w (bool state) |
| 105 | 104 | { |
| 106 | 105 | m_fdc_intrq = state ? 0x80 : 0; |
| 107 | 106 | } |
| 108 | 107 | |
| 109 | | WRITE_LINE_MEMBER( mbee_state::mbee_fdc_drq_w ) |
| 108 | void mbee_state::fdc_drq_w (bool state) |
| 110 | 109 | { |
| 111 | 110 | m_fdc_drq = state ? 0x80 : 0; |
| 112 | 111 | } |
| 113 | 112 | |
| 114 | | const wd17xx_interface mbee_wd17xx_interface = |
| 115 | | { |
| 116 | | DEVCB_NULL, |
| 117 | | DEVCB_DRIVER_LINE_MEMBER(mbee_state, mbee_fdc_intrq_w), |
| 118 | | DEVCB_DRIVER_LINE_MEMBER(mbee_state, mbee_fdc_drq_w), |
| 119 | | {FLOPPY_0, FLOPPY_1, NULL, NULL } |
| 120 | | }; |
| 121 | 113 | |
| 122 | 114 | READ8_MEMBER( mbee_state::mbee_fdc_status_r ) |
| 123 | 115 | { |
| r24082 | r24083 | |
| 134 | 126 | d2 side (1=side 1) |
| 135 | 127 | d1..d0 drive select (0 to 3) */ |
| 136 | 128 | |
| 137 | | wd17xx_set_drive(m_fdc, data & 3); |
| 138 | | wd17xx_set_side(m_fdc, BIT(data, 2)); |
| 139 | | wd17xx_dden_w(m_fdc, !BIT(data, 3)); |
| 140 | | /* no idea what turns the motors on & off, guessing it could be drive select |
| 141 | | commented out because it prevents 128k and 256TC from booting up */ |
| 142 | | //floppy_mon_w(floppy_get_device(machine(), data & 3), CLEAR_LINE); // motor on |
| 129 | floppy_image_device *floppy = NULL; |
| 130 | if ((data & 3)==0) |
| 131 | floppy = m_floppy0->get_device(); |
| 132 | else |
| 133 | if ((data & 3)==1) |
| 134 | floppy = m_floppy1->get_device(); |
| 135 | |
| 136 | m_fdc->set_floppy(floppy); |
| 137 | |
| 138 | if (floppy) |
| 139 | { |
| 140 | floppy->mon_w(0); |
| 141 | floppy->ss_w(BIT(data, 2)); |
| 142 | } |
| 143 | |
| 144 | //m_fdc->dden_w(!BIT(data, 3)); // not sure about polarity in the new system |
| 143 | 145 | } |
| 144 | 146 | |
| 145 | 147 | /*********************************************************** |
| r24082 | r24083 | |
| 528 | 530 | |
| 529 | 531 | void mbee_state::machine_reset_common_disk() |
| 530 | 532 | { |
| 531 | | /* These values need to be fine tuned or the fdc repaired */ |
| 532 | | wd17xx_set_pause_time(m_fdc, 45); /* default is 40 usec if not set */ |
| 533 | | // wd17xx_set_complete_command_delay(m_fdc, 50); /* default is 12 usec if not set */ |
| 533 | floppy_connector *con = machine().device<floppy_connector>("fdc:0"); |
| 534 | floppy_image_device *floppy = con ? con->get_device() : 0; |
| 535 | if (floppy) |
| 536 | { |
| 537 | m_fdc->set_floppy(floppy); |
| 538 | //m_fdc->setup_intrq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_intrq_w), this)); |
| 539 | //m_fdc->setup_drq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_drq_w), this)); |
| 540 | |
| 541 | floppy->ss_w(0); |
| 542 | } |
| 534 | 543 | } |
| 535 | 544 | |
| 536 | 545 | MACHINE_RESET_MEMBER(mbee_state,mbee) |
| r24082 | r24083 | |
| 683 | 692 | UINT8 *RAM = memregion("maincpu")->base(); |
| 684 | 693 | m_boot->configure_entries(0, 2, &RAM[0x0000], 0xe000); |
| 685 | 694 | m_size = 0xe000; |
| 695 | m_fdc->setup_intrq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_intrq_w), this)); |
| 696 | m_fdc->setup_drq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_drq_w), this)); |
| 686 | 697 | } |
| 687 | 698 | |
| 688 | 699 | DRIVER_INIT_MEMBER(mbee_state,mbee64) |
| r24082 | r24083 | |
| 698 | 709 | m_boot->configure_entry(1, &RAM[0x0000]); |
| 699 | 710 | |
| 700 | 711 | m_size = 0xf000; |
| 712 | m_fdc->setup_intrq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_intrq_w), this)); |
| 713 | m_fdc->setup_drq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_drq_w), this)); |
| 701 | 714 | } |
| 702 | 715 | |
| 703 | 716 | DRIVER_INIT_MEMBER(mbee_state,mbee128) |
| r24082 | r24083 | |
| 718 | 731 | m_bank8h->configure_entry(0, &RAM[0x0800]); // rom |
| 719 | 732 | |
| 720 | 733 | m_size = 0x8000; |
| 734 | m_fdc->setup_intrq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_intrq_w), this)); |
| 735 | m_fdc->setup_drq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_drq_w), this)); |
| 721 | 736 | } |
| 722 | 737 | |
| 723 | 738 | DRIVER_INIT_MEMBER(mbee_state,mbee256) |
| r24082 | r24083 | |
| 741 | 756 | timer_set(attotime::from_hz(25), TIMER_MBEE256_KBD); /* timer for kbd */ |
| 742 | 757 | |
| 743 | 758 | m_size = 0x8000; |
| 759 | m_fdc->setup_intrq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_intrq_w), this)); |
| 760 | m_fdc->setup_drq_cb(wd2793_t::line_cb(FUNC(mbee_state::fdc_drq_w), this)); |
| 744 | 761 | } |
| 745 | 762 | |
| 746 | 763 | DRIVER_INIT_MEMBER(mbee_state,mbeett) |
trunk/src/mess/includes/mbee.h
| r24082 | r24083 | |
| 7 | 7 | #ifndef MBEE_H_ |
| 8 | 8 | #define MBEE_H_ |
| 9 | 9 | |
| 10 | | #include "machine/wd17xx.h" |
| 10 | #include "emu.h" |
| 11 | 11 | #include "imagedev/snapquik.h" |
| 12 | 12 | #include "machine/z80pio.h" |
| 13 | 13 | #include "imagedev/cassette.h" |
| r24082 | r24083 | |
| 19 | 19 | #include "cpu/z80/z80daisy.h" |
| 20 | 20 | #include "machine/mc146818.h" |
| 21 | 21 | #include "sound/wave.h" |
| 22 | | #include "imagedev/flopdrv.h" |
| 23 | | #include "formats/basicdsk.h" |
| 22 | #include "machine/wd_fdc.h" |
| 24 | 23 | |
| 25 | 24 | |
| 26 | 25 | class mbee_state : public driver_device |
| r24082 | r24083 | |
| 43 | 42 | m_printer(*this, "centronics"), |
| 44 | 43 | m_crtc(*this, "crtc"), |
| 45 | 44 | m_fdc(*this, "fdc"), |
| 45 | m_floppy0(*this, "fdc:0"), |
| 46 | m_floppy1(*this, "fdc:1"), |
| 46 | 47 | m_rtc(*this, "rtc"), |
| 47 | 48 | m_boot(*this, "boot"), |
| 48 | 49 | m_pak(*this, "pak"), |
| r24082 | r24083 | |
| 74 | 75 | m_io_x13(*this, "X13"), |
| 75 | 76 | m_io_x14(*this, "X14") { } |
| 76 | 77 | |
| 77 | | required_device<cpu_device> m_maincpu; |
| 78 | | required_device<z80pio_device> m_pio; |
| 79 | | required_device<cassette_image_device> m_cassette; |
| 80 | | required_device<wave_device> m_wave; |
| 81 | | required_device<speaker_sound_device> m_speaker; |
| 82 | | required_device<centronics_device> m_printer; |
| 83 | | required_device<mc6845_device> m_crtc; |
| 84 | | optional_device<wd2793_device> m_fdc; |
| 85 | | optional_device<mc146818_device> m_rtc; |
| 86 | 78 | DECLARE_WRITE8_MEMBER( mbee_04_w ); |
| 87 | 79 | DECLARE_WRITE8_MEMBER( mbee_06_w ); |
| 88 | 80 | DECLARE_READ8_MEMBER( mbee_07_r ); |
| r24082 | r24083 | |
| 123 | 115 | DECLARE_WRITE_LINE_MEMBER( pio_ardy ); |
| 124 | 116 | DECLARE_READ8_MEMBER(mbee_fdc_status_r); |
| 125 | 117 | DECLARE_WRITE8_MEMBER(mbee_fdc_motor_w); |
| 126 | | DECLARE_WRITE_LINE_MEMBER(mbee_fdc_intrq_w); |
| 127 | | DECLARE_WRITE_LINE_MEMBER(mbee_fdc_drq_w); |
| 128 | | size_t m_size; |
| 129 | | UINT8 m_clock_pulse; |
| 130 | | UINT8 m_mbee256_key_available; |
| 131 | | UINT8 m_fdc_intrq; |
| 132 | | UINT8 m_fdc_drq; |
| 133 | | UINT8 m_mbee256_was_pressed[15]; |
| 134 | | UINT8 m_mbee256_q[20]; |
| 135 | | UINT8 m_mbee256_q_pos; |
| 136 | | UINT8 m_framecnt; |
| 137 | | UINT8 *m_p_gfxram; |
| 138 | | UINT8 *m_p_colorram; |
| 139 | | UINT8 *m_p_videoram; |
| 140 | | UINT8 *m_p_attribram; |
| 141 | | UINT8 m_08; |
| 142 | | UINT8 m_0a; |
| 143 | | UINT8 m_0b; |
| 144 | | UINT8 m_1c; |
| 145 | | UINT8 m_is_premium; |
| 146 | | UINT8 m_sy6545_cursor[16]; |
| 147 | | UINT8 m_sy6545_status; |
| 148 | | UINT8 m_speed; |
| 149 | | UINT8 m_flash; |
| 150 | | UINT16 m_cursor; |
| 151 | | UINT8 m_sy6545_reg[32]; |
| 152 | | UINT8 m_sy6545_ind; |
| 153 | | void sy6545_cursor_configure(); |
| 154 | | void keyboard_matrix_r(int offs); |
| 155 | | void mbee_video_kbd_scan(int param); |
| 156 | 118 | DECLARE_DRIVER_INIT(mbeepc85); |
| 157 | 119 | DECLARE_DRIVER_INIT(mbee256); |
| 158 | 120 | DECLARE_DRIVER_INIT(mbee56); |
| r24082 | r24083 | |
| 182 | 144 | TIMER_CALLBACK_MEMBER(mbee_reset); |
| 183 | 145 | DECLARE_QUICKLOAD_LOAD_MEMBER( mbee ); |
| 184 | 146 | DECLARE_QUICKLOAD_LOAD_MEMBER( mbee_z80bin ); |
| 147 | DECLARE_FLOPPY_FORMATS(floppy_formats); |
| 148 | UINT8 *m_p_videoram; |
| 149 | UINT8 *m_p_gfxram; |
| 150 | UINT8 *m_p_colorram; |
| 151 | UINT8 *m_p_attribram; |
| 152 | UINT8 m_speed; |
| 153 | UINT8 m_flash; |
| 154 | UINT8 m_framecnt; |
| 155 | UINT16 m_cursor; |
| 156 | UINT8 m_08; |
| 157 | UINT8 m_1c; |
| 158 | void mbee_video_kbd_scan(int param); |
| 159 | UINT8 m_sy6545_cursor[16]; |
| 185 | 160 | |
| 186 | | protected: |
| 161 | private: |
| 162 | size_t m_size; |
| 163 | UINT8 m_clock_pulse; |
| 164 | UINT8 m_mbee256_key_available; |
| 165 | UINT8 m_fdc_intrq; |
| 166 | UINT8 m_fdc_drq; |
| 167 | UINT8 m_mbee256_was_pressed[15]; |
| 168 | UINT8 m_mbee256_q[20]; |
| 169 | UINT8 m_mbee256_q_pos; |
| 170 | UINT8 m_0a; |
| 171 | UINT8 m_0b; |
| 172 | UINT8 m_is_premium; |
| 173 | UINT8 m_sy6545_status; |
| 174 | UINT8 m_sy6545_reg[32]; |
| 175 | UINT8 m_sy6545_ind; |
| 176 | void sy6545_cursor_configure(); |
| 177 | void keyboard_matrix_r(int offs); |
| 178 | required_device<cpu_device> m_maincpu; |
| 179 | required_device<z80pio_device> m_pio; |
| 180 | required_device<cassette_image_device> m_cassette; |
| 181 | required_device<wave_device> m_wave; |
| 182 | required_device<speaker_sound_device> m_speaker; |
| 183 | required_device<centronics_device> m_printer; |
| 184 | required_device<mc6845_device> m_crtc; |
| 185 | optional_device<wd2793_t> m_fdc; |
| 186 | optional_device<floppy_connector> m_floppy0; |
| 187 | optional_device<floppy_connector> m_floppy1; |
| 188 | optional_device<mc146818_device> m_rtc; |
| 187 | 189 | required_memory_bank m_boot; |
| 188 | 190 | optional_memory_bank m_pak; |
| 189 | 191 | optional_memory_bank m_telcom; |
| r24082 | r24083 | |
| 216 | 218 | |
| 217 | 219 | void machine_reset_common_disk(); |
| 218 | 220 | virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr); |
| 221 | void fdc_intrq_w(bool state); |
| 222 | void fdc_drq_w(bool state); |
| 219 | 223 | }; |
| 220 | 224 | |
| 221 | 225 | |
| 222 | 226 | /*----------- defined in machine/mbee.c -----------*/ |
| 223 | 227 | |
| 224 | | extern const wd17xx_interface mbee_wd17xx_interface; |
| 228 | //extern const wd17xx_interface mbee_wd17xx_interface; |
| 225 | 229 | extern const z80pio_interface mbee_z80pio_intf; |
| 226 | 230 | |
| 227 | 231 | /*----------- defined in video/mbee.c -----------*/ |